/*
Theme Name: NewsPress
Theme URI: https://example.com/themes/newspress
Author: NewsPress Studio
Author URI: https://example.com
Description: NewsPress 是一款面向自媒体与资讯站的现代化 WordPress 杂志主题。内置可视化首页模块布局、主题设置面板、文章与视频模板、SEO 与性能优化选项，安装即可搭建专业的内容站点。默认使用经典编辑器（TinyMCE），支持中文站的 ICP 与公安备案展示（内置 / 自定义图标）、页脚频道导航菜单、手机底部导航栏。
Version: 2.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: newspress
Domain Path: /languages
Tags: news, blog, magazine, custom-menu, custom-logo, featured-images, footer-widgets, translation-ready, responsive-layout, two-columns, custom-colors, threaded-comments
Requires at least: 6.1
Tested up to: 6.8
Requires PHP: 7.4
Stable tag: 2.0.0
*/

/* ==========================================================================
   0. 设计令牌
   ========================================================================== */
:root {
  --np-primary: #2271b1;
  --np-primary-dark: #135e96;
  --np-primary-soft: rgba(34, 113, 177, 0.1);
  --np-accent: #d63638;
  --np-text: #1f2328;
  --np-text-2: #4a5058;
  --np-muted: #7a838f;
  --np-line: #e6e9ee;
  --np-bg: #ffffff;
  --np-bg-soft: #f6f8fa;
  --np-bg-deep: #0f1419;
  --np-radius: 8px;
  --np-radius-sm: 5px;
  --np-container: 1200px;
  --np-sidebar: 320px;
  --np-gap: 24px;
  --np-header-h: 64px;
  --np-shadow: 0 1px 3px rgba(16, 24, 40, 0.06), 0 8px 24px rgba(16, 24, 40, 0.06);
  --np-transition: 200ms cubic-bezier(0.4, 0, 0.2, 1);
}

/* 暗色模式令牌（由主题设置切换 body.np-dark） */
body.np-dark {
  --np-primary: #4f9ce8;
  --np-primary-soft: rgba(79, 156, 232, 0.16);
  --np-text: #e8eaed;
  --np-text-2: #b9c0c9;
  --np-muted: #8b939e;
  --np-line: #262c33;
  --np-bg: #14181d;
  --np-bg-soft: #1b2127;
  --np-shadow: 0 1px 3px rgba(0, 0, 0, 0.4), 0 8px 24px rgba(0, 0, 0, 0.35);
}

/* ==========================================================================
   1. 基础重置
   ========================================================================== */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--np-bg);
  color: var(--np-text);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC',
    'Hiragino Sans GB', 'Microsoft YaHei', 'Helvetica Neue', Arial, sans-serif;
  font-size: 15px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  transition: background var(--np-transition), color var(--np-transition);
}

body.np-dark {
  background: var(--np-bg);
}

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--np-transition);
}

a:hover {
  color: var(--np-primary);
}

img,
svg,
video {
  max-width: 100%;
  height: auto;
  display: block;
}

h1, h2, h3, h4, h5, h6 {
  margin: 0 0 12px;
  line-height: 1.35;
  font-weight: 700;
  color: inherit;
}

h1 { font-size: 28px; }
h2 { font-size: 22px; }
h3 { font-size: 18px; }
h4 { font-size: 16px; }

p {
  margin: 0 0 14px;
}

ul, ol {
  margin: 0 0 14px;
  padding-left: 22px;
}

blockquote {
  margin: 20px 0;
  padding: 12px 18px;
  border-left: 3px solid var(--np-primary);
  background: var(--np-bg-soft);
  color: var(--np-text-2);
  border-radius: 0 var(--np-radius-sm) var(--np-radius-sm) 0;
}

code, pre, kbd {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 13px;
}

pre {
  background: var(--np-bg-soft);
  padding: 14px 16px;
  border-radius: var(--np-radius-sm);
  overflow-x: auto;
  border: 1px solid var(--np-line);
}

code {
  background: var(--np-bg-soft);
  padding: 2px 6px;
  border-radius: 4px;
}

table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 16px;
}

th, td {
  border: 1px solid var(--np-line);
  padding: 8px 12px;
  text-align: left;
}

.screen-reader-text {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.screen-reader-text:focus {
  position: static !important;
  width: auto;
  height: auto;
  clip: auto;
  padding: 8px 14px;
  background: var(--np-primary);
  color: #fff;
  z-index: 100;
}

/* ==========================================================================
   2. 布局骨架
   ========================================================================== */
.np-container {
  width: 100%;
  max-width: var(--np-container);
  margin: 0 auto;
  padding: 0 20px;
}

.np-container--narrow {
  max-width: 820px;
}

.np-site {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.np-main {
  flex: 1 0 auto;
  padding: var(--np-gap) 0 48px;
}

.np-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) var(--np-sidebar);
  gap: var(--np-gap);
  align-items: start;
}

.np-layout--left {
  grid-template-columns: var(--np-sidebar) minmax(0, 1fr);
}

.np-layout--left .np-content { order: 2; }
.np-layout--left .np-sidebar-col { order: 1; }

.np-layout--none {
  grid-template-columns: minmax(0, 1fr);
}

.np-layout--none .np-sidebar-col {
  display: none;
}

/* ==========================================================================
   3. 顶部导航
   ========================================================================== */
.np-header {
  position: relative;
  z-index: 60;
  background: var(--np-bg);
  border-bottom: 1px solid var(--np-line);
}

.np-header.is-sticky {
  position: sticky;
  top: 0;
  backdrop-filter: saturate(180%) blur(10px);
  background: color-mix(in srgb, var(--np-bg) 88%, transparent);
}

/* 手机上下滑时头部滑走 / 滑回来（JS 给 body 头部的兄弟节点加 is-hidden）。
 * 只动 transform，不碰 top，避免重排；阴影和搜索面板一起跟着平移，
 * 否则收起时会在屏幕顶端留一条边。 */
@media (max-width: 960px) {
  /* 「滚动时自动收起顶部导航」只有在头部吸顶时才有意义：
     没开「固定头部」时 header 跟着文档流一起滚出视口，
     translateY(-100%) 的位移根本看不出来，功能形同失效。
     所以开了自动收起的手机端无条件吸顶。 */
  .np-header--autohide {
    position: sticky;
    top: 0;
    background: color-mix(in srgb, var(--np-bg) 88%, transparent);
    backdrop-filter: saturate(180%) blur(10px);
    transition: transform 0.28s cubic-bezier(0.32, 0.72, 0, 1);
    will-change: transform;
  }

  .np-header--autohide.is-sticky {
    transition: transform 0.28s cubic-bezier(0.32, 0.72, 0, 1);
    will-change: transform;
  }

  .np-header.is-hidden {
    transform: translateY(-100%);
  }

  /* 抽屉打开时头部必须原位，不然关掉抽屉会看到它从上面掉下来 */
  body.np-drawer-on .np-header {
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .np-header.is-sticky,
  .np-header--autohide,
  .np-mnav--autohide,
  .np-fab {
    transition: none;
  }
}

.np-header__inner {
  display: flex;
  align-items: center;
  gap: var(--np-gap);
  height: var(--np-header-h);
}

.np-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: none;
}

.np-brand__logo {
  max-height: 36px;
  width: auto;
}

.np-brand__name {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.4px;
}

.np-brand__name em {
  font-style: normal;
  color: var(--np-primary);
}

.np-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  flex: 1 1 auto;
  min-width: 0;
}

.np-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  align-items: center;
  gap: 2px;
}

.np-nav li {
  position: relative;
}

.np-nav a {
  display: block;
  padding: 8px 12px;
  border-radius: var(--np-radius-sm);
  font-size: 15px;
  font-weight: 500;
  color: var(--np-text-2);
  white-space: nowrap;
}

.np-nav a:hover,
.np-nav .current-menu-item > a,
.np-nav .current-menu-ancestor > a {
  color: var(--np-primary);
  background: var(--np-primary-soft);
}

/* 二级菜单 */
.np-nav ul ul {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 168px;
  background: var(--np-bg);
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  box-shadow: var(--np-shadow);
  padding: 6px;
  flex-direction: column;
  gap: 0;
}

.np-nav ul li:hover > ul {
  display: flex;
}

.np-nav ul ul a {
  font-size: 14px;
  padding: 7px 10px;
}

.np-header__actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: none;
}

.np-search-toggle,
.np-dark-toggle,
.np-translate-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: transparent;
  color: var(--np-text-2);
  cursor: pointer;
  transition: var(--np-transition);
}

.np-search-toggle:hover,
.np-dark-toggle:hover,
.np-translate-toggle:hover {
  color: var(--np-primary);
  border-color: var(--np-primary);
}

.np-search-toggle svg,
.np-dark-toggle svg,
.np-translate-toggle svg {
  width: 16px;
  height: 16px;
}

/* --- 网页翻译（translate.js）：头部小图标 + 下拉选语种 --- */
.np-translate-wrap {
  position: relative;
  flex: none;
}

.np-translate-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 90;
  display: none;
  width: 184px;
  max-height: 320px;
  overflow-y: auto;
  padding: 6px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
  box-shadow: var(--np-shadow);
  overscroll-behavior: contain;
}

.np-translate-menu.is-open {
  display: block;
}

.np-translate-menu__item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 8px 10px;
  border-radius: var(--np-radius-sm);
  color: var(--np-text-2);
  font-size: 13px;
  line-height: 1.2;
  white-space: nowrap;
}

.np-translate-menu__item em {
  flex: none;
  font-style: normal;
  font-size: 11px;
  color: var(--np-muted);
}

.np-translate-menu__item:hover {
  background: var(--np-bg-soft);
  color: var(--np-text);
}

.np-translate-menu__item.is-active {
  background: var(--np-primary-soft);
  color: var(--np-primary);
}

.np-translate-menu__item.is-active em {
  color: var(--np-primary);
}

.np-translate-toggle[aria-expanded="true"] {
  color: var(--np-primary);
  border-color: var(--np-primary);
}

/* 首次加载 translate.js 时图标呼吸，避免点了没反馈 */
.np-translate-toggle.is-loading svg,
.np-drawer__translate.is-loading svg {
  animation: np-translate-pulse 1s ease-in-out infinite;
}

@keyframes np-translate-pulse {
  0%, 100% { opacity: 0.4; }
  50%      { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .np-translate-toggle.is-loading svg,
  .np-drawer__translate.is-loading svg {
    animation: none;
  }
}

/* --- 语言切换 --- */
.np-lang {
  position: relative;
  flex: none;
}

.np-lang__btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  height: 34px;
  padding: 0 10px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: transparent;
  color: var(--np-text-2);
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--np-transition);
}

.np-lang__btn:hover {
  color: var(--np-primary);
  border-color: var(--np-primary);
}

.np-lang__list {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  z-index: 70;
  min-width: 132px;
  margin: 0;
  padding: 6px;
  list-style: none;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg);
  box-shadow: var(--np-shadow);
  display: none;
}

.np-lang.is-open .np-lang__list {
  display: block;
}

.np-lang__list a {
  display: block;
  padding: 7px 10px;
  border-radius: 6px;
  font-size: 13.5px;
  color: var(--np-text-2);
}

.np-lang__list a:hover,
.np-lang__list a.is-active {
  background: var(--np-primary-soft);
  color: var(--np-primary);
}

.np-user-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  color: var(--np-text-2);
  overflow: hidden;
  transition: var(--np-transition);
}

.np-user-toggle:hover {
  color: var(--np-primary);
  border-color: var(--np-primary);
}

.np-user-toggle svg {
  width: 16px;
  height: 16px;
}

.np-user-toggle__avatar {
  width: 100%;
  height: 100%;
  display: block;
}

.np-header__search {
  display: none;
  border-top: 1px solid var(--np-line);
  padding: 12px 0;
  background: var(--np-bg);
}

.np-header__search.is-open {
  display: block;
}

.np-search-form {
  display: flex;
  gap: 8px;
}

.np-search-form input[type='search'],
.np-search-form .np-field {
  flex: 1 1 auto;
  box-sizing: border-box;
  width: 100%;
  /* search 类型输入框在部分浏览器里会被内容盒压矮，用 min-height 锁死与按钮同高。 */
  height: 38px;
  min-height: 38px;
  line-height: 36px;
  padding: 0 12px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg);
  color: var(--np-text);
  font-size: 14px;
  font-family: inherit;
  outline: none;
  -webkit-appearance: none;
  appearance: none;
}

.np-search-form input:focus {
  border-color: var(--np-primary);
}

.np-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  flex: none;
  white-space: nowrap;
  height: 38px;
  padding: 0 18px;
  border: 1px solid var(--np-primary);
  border-radius: var(--np-radius-sm);
  background: var(--np-primary);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--np-transition);
}

.np-btn:hover {
  background: var(--np-primary-dark);
  border-color: var(--np-primary-dark);
  color: #fff;
}

.np-btn--ghost {
  background: transparent;
  color: var(--np-primary);
}

.np-btn--ghost:hover {
  background: var(--np-primary-soft);
  color: var(--np-primary);
}

.np-menu-toggle {
  display: none;
}

/* 抽屉里的额外块在桌面上不存在，统一隐藏；手机断点里再逐块 display 回来。
 * 必须限定桌面宽度并加 .np-nav 前缀：会员横幅 / 语言胶囊本身是 <a>，
 * 会被下面 .np-nav a{display:block}（特异性更高）反过来盖住，导致桌面导航里
 * 露出一条「开通会员」。放进 min-width 媒体后手机端这条规则根本不参与层叠。 */
@media (min-width: 961px) {
  .np-nav .np-drawer__top,
  .np-nav .np-drawer__langs,
  .np-nav .np-drawer__vipbar,
  .np-nav .np-drawer__account,
  .np-nav .np-translate-menu--inline,
  .np-drawer-mask {
    display: none;
  }
}

/* ==========================================================================
   4. 首页模块
   ========================================================================== */
.np-module {
  margin-bottom: 36px;
}

.np-module__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--np-line);
}

.np-module__title {
  margin: 0;
  font-size: 19px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
}

.np-module__title::before {
  content: '';
  width: 4px;
  height: 18px;
  border-radius: 2px;
  background: var(--np-primary);
}

.np-module__more {
  font-size: 13px;
  color: var(--np-muted);
}

.np-module__more:hover {
  color: var(--np-primary);
}

/* --- 轮播 --- */
.np-slider {
  position: relative;
  border-radius: var(--np-radius);
  overflow: hidden;
  background: var(--np-bg-deep);
  box-shadow: var(--np-shadow);
}

.np-slider__track {
  display: flex;
  transition: transform 500ms cubic-bezier(0.4, 0, 0.2, 1);
}

.np-slider__slide {
  flex: 0 0 100%;
  position: relative;
  min-height: 340px;
  display: flex;
  align-items: flex-end;
}

.np-slider__slide img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.np-slider__slide::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(8, 12, 18, 0.86) 0%, rgba(8, 12, 18, 0.15) 55%, rgba(8, 12, 18, 0) 100%);
}

.np-slider__caption {
  position: relative;
  z-index: 2;
  padding: 28px 32px;
  color: #fff;
  max-width: 720px;
}

.np-slider__tag {
  display: inline-block;
  margin-bottom: 10px;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--np-primary);
  color: #fff;
  font-size: 12px;
  font-weight: 600;
}

.np-slider__caption h2 {
  margin: 0 0 8px;
  font-size: 26px;
  color: #fff;
}

.np-slider__caption p {
  margin: 0;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.78);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.np-slider__dots {
  position: absolute;
  right: 18px;
  bottom: 18px;
  z-index: 3;
  display: flex;
  gap: 7px;
}

.np-slider__dot {
  width: 8px;
  height: 8px;
  border: 0;
  padding: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.45);
  cursor: pointer;
  transition: var(--np-transition);
}

.np-slider__dot.is-active {
  width: 22px;
  border-radius: 999px;
  background: #fff;
}

/* --- 公告 --- */
.np-notice {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 16px;
  border: 1px solid var(--np-line);
  border-left: 3px solid var(--np-accent);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg-soft);
  font-size: 14px;
}

.np-notice__icon {
  flex: none;
  color: var(--np-accent);
  font-weight: 700;
}

/* 跑马灯：视口截断，轨道滚动两份同样的文本，无缝循环 */
.np-notice__viewport {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  /* 只在右缘做淡出，左侧保留文字清晰（遮罩压左缘会把首字母切一半）。 */
  -webkit-mask-image: linear-gradient(90deg, #000 0, #000 92%, transparent);
  mask-image: linear-gradient(90deg, #000 0, #000 92%, transparent);
}

.np-notice__track {
  display: inline-flex;
  white-space: nowrap;
  will-change: transform;
}

.np-notice__text {
  flex: none;
  padding-right: 64px;
  color: var(--np-text-2);
}

.np-notice--scroll .np-notice__track {
  animation: np-notice-marquee 18s linear infinite;
}

@keyframes np-notice-marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* 窄屏文字多、滚动距离长，放慢速度免得闪得眼花 */
@media (max-width: 640px) {
  .np-notice {
    padding: 9px 12px;
    font-size: 13px;
  }
  .np-notice--scroll .np-notice__track {
    animation-duration: 26s;
  }
  .np-notice__text {
    padding-right: 44px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .np-notice--scroll .np-notice__track {
    animation: none;
  }
}

.np-notice__link {
  flex: none;
  color: var(--np-primary);
  font-weight: 600;
  font-size: 13px;
}

/* --- 分类导航 --- */
.np-cats {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.np-cat {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border: 1px solid var(--np-line);
  border-radius: 999px;
  background: var(--np-bg);
  font-size: 14px;
  font-weight: 500;
  transition: var(--np-transition);
}

.np-cat:hover {
  border-color: var(--np-primary);
  color: var(--np-primary);
  transform: translateY(-1px);
}

.np-cat__count {
  font-size: 12px;
  color: var(--np-muted);
}

.np-cat__dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--np-primary);
}

/* --- 文章条目：列表 --- */
.np-post-list {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.np-post-item {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 18px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--np-line);
}

.np-post-item:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.np-post-item__thumb {
  position: relative;
  border-radius: var(--np-radius);
  overflow: hidden;
  aspect-ratio: 16 / 10;
  background: var(--np-bg-soft);
}

.np-post-item__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 400ms ease;
}

.np-post-item:hover .np-post-item__thumb img {
  transform: scale(1.05);
}

.np-post-item__thumb--empty {
  display: flex;
  align-items: center;
  justify-content: center;
  /* 没有封面时父级没有真实高度可继承，height:100% 会塌陷成 0，
     导致文字压到上方缩略图区域，这里给一个最小高度兜底。 */
  min-height: 100px;
  color: var(--np-muted);
  font-size: 12px;
  background: linear-gradient(135deg, var(--np-primary-soft), transparent);
}

.np-post-item__badge {
  position: absolute;
  left: 8px;
  top: 8px;
  padding: 2px 8px;
  border-radius: 4px;
  background: var(--np-accent);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
}

.np-post-item__body {
  min-width: 0;
}

.np-post-item__title {
  margin: 0 0 8px;
  font-size: 17px;
  line-height: 1.45;
}

.np-post-item__title a {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.np-post-item__excerpt {
  margin: 0 0 10px;
  font-size: 14px;
  color: var(--np-text-2);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.np-post-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  font-size: 12.5px;
  color: var(--np-muted);
}

.np-post-meta__author {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.np-post-meta__avatar {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  object-fit: cover;
}

/* --- 文章条目：网格 / 卡片 --- */
.np-post-grid {
  display: grid;
  grid-template-columns: repeat(var(--np-cols, 3), minmax(0, 1fr));
  gap: 20px;
}

.np-card {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
  overflow: hidden;
  transition: var(--np-transition);
}

.np-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--np-shadow);
  border-color: color-mix(in srgb, var(--np-primary) 35%, var(--np-line));
}

.np-card__thumb {
  position: relative;
  aspect-ratio: 16 / 10;
  background: var(--np-bg-soft);
  overflow: hidden;
}

.np-card__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 400ms ease;
}

.np-card:hover .np-card__thumb img {
  transform: scale(1.05);
}

.np-card__body {
  padding: 14px 16px 16px;
}

.np-card__title {
  margin: 0 0 8px;
  font-size: 15.5px;
  line-height: 1.45;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* --- 精选排行 --- */
.np-pick {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.np-pick__item {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.np-pick__rank {
  flex: none;
  width: 22px;
  height: 22px;
  border-radius: 5px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  color: var(--np-muted);
  background: var(--np-bg-soft);
}

.np-pick__item:nth-child(1) .np-pick__rank,
.np-pick__item:nth-child(2) .np-pick__rank,
.np-pick__item:nth-child(3) .np-pick__rank {
  background: var(--np-primary);
  color: #fff;
}

.np-pick__title {
  font-size: 14.5px;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* --- 视频模块 --- */
.np-video-grid {
  display: grid;
  grid-template-columns: repeat(var(--np-cols, 3), minmax(0, 1fr));
  gap: 20px;
  align-items: start;
}

.np-video-card {
  min-width: 0;
}

.np-video-card__thumb {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  /* 部分浏览器在 grid 项内不会自动用 aspect-ratio 撑高，给一个 min-height 兜底，
     否则卡片会被压成一条，标题直接贴到缩略图上。 */
  min-height: 120px;
  border-radius: var(--np-radius);
  overflow: hidden;
  background: var(--np-bg-deep);
}

.np-video-card__thumb img,
.np-video-card__thumb .np-post-item__thumb--empty {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  min-height: 120px;
  object-fit: cover;
  opacity: 0.82;
}

.np-video-card__play {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.np-video-card__play span {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  color: #111;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  transition: var(--np-transition);
}

.np-video-card:hover .np-video-card__play span {
  transform: scale(1.12);
}

.np-video-card__meta {
  position: absolute;
  right: 8px;
  bottom: 8px;
  padding: 2px 7px;
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.68);
  color: #fff;
  font-size: 11.5px;
}

/* --- 视频播放列表页 --- */
/* 页头做成深色 hero：视频页的主角本来就是播放器，页头用同一套深色语言
 * 跟播放器框呼应，比一行黑字 + 一行灰字有页面感。 */
.np-video-head {
  margin: 4px 0 22px;
  padding: 26px 28px;
  border-radius: 16px;
  background: linear-gradient(135deg, #1b2431, #0d1117);
  color: #fff;
}

.np-video-head__title {
  margin: 0 0 8px;
  font-size: 26px;
  line-height: 1.3;
  color: #fff;
  letter-spacing: -0.01em;
}

.np-video-head__sub {
  margin: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.85);
  font-size: 12.5px;
}

.np-video-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 22px;
  align-items: start;
  margin-bottom: 56px;
}

.np-video-stage {
  min-width: 0;
}

.np-video-stage__frame {
  position: relative;
  aspect-ratio: 16 / 9;
  width: 100%;
  overflow: hidden;
  border-radius: 14px;
  background: #0d1117;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.14);
  transition: box-shadow 0.25s ease;
}

.np-video-stage__frame:hover {
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.2);
}

.np-video-stage__frame iframe,
.np-video-stage__frame video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
  background: #000;
}

.np-video-stage__link {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #1b2431, #0d1117);
}

.np-video-stage__meta {
  padding: 16px 2px 0;
}

.np-video-stage__title {
  margin: 0 0 8px;
  font-size: 21px;
  line-height: 1.35;
}

.np-video-stage__desc {
  margin: 0 0 12px;
  font-size: 14px;
  line-height: 1.7;
  color: var(--np-text-2);
}

.np-video-stage__tags {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.np-video-chip {
  padding: 3px 10px;
  border-radius: 999px;
  background: rgba(34, 113, 177, 0.1);
  color: var(--np-primary);
  font-size: 12.5px;
  font-weight: 600;
}

.np-video-chip--muted {
  background: var(--np-bg-soft);
  color: var(--np-muted);
  font-variant-numeric: tabular-nums;
}

.np-video-stage__origin {
  margin-left: auto;
  font-size: 13px;
  color: var(--np-muted);
  text-decoration: none;
}

.np-video-stage__origin:hover {
  color: var(--np-primary);
}

.np-video-stage__nav {
  display: flex;
  gap: 10px;
  margin-top: 16px;
}

/* 上一个 / 下一个：原来是无样式的浏览器默认按钮，和整体设计语言脱节 */
.np-video-nav {
  padding: 8px 18px;
  border: 1px solid var(--np-line);
  border-radius: 999px;
  background: var(--np-bg);
  color: var(--np-text-2);
  font-size: 13.5px;
  font-family: inherit;
  cursor: pointer;
  transition: color var(--np-transition), border-color var(--np-transition);
}

.np-video-nav:hover {
  border-color: var(--np-primary);
  color: var(--np-primary);
}

.np-video-nav:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

/* 播放列表 */
.np-video-list {
  position: sticky;
  top: calc(var(--np-header-h) + 20px);
  border: 1px solid var(--np-line);
  border-radius: 14px;
  background: var(--np-bg);
  overflow: hidden;
}

.np-video-list__head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--np-line);
  background: var(--np-bg-soft);
}

.np-video-list__head h3 {
  margin: 0;
  font-size: 15px;
}

.np-video-list__count {
  margin-left: auto;
  padding: 1px 9px;
  border-radius: 999px;
  background: var(--np-primary-soft);
  color: var(--np-primary);
  font-size: 12px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.np-video-list__group {
  margin: 0;
  padding: 10px 16px 6px;
  font-size: 12px;
  font-weight: 600;
  color: var(--np-muted);
  letter-spacing: 0.04em;
}

.np-video-list__items {
  margin: 0;
  padding: 6px;
  list-style: none;
  max-height: 520px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--np-line) transparent;
}

.np-video-list__items::-webkit-scrollbar {
  width: 6px;
}

.np-video-list__items::-webkit-scrollbar-thumb {
  border-radius: 3px;
  background: var(--np-line);
}

.np-video-item {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  width: 100%;
  padding: 8px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  text-align: left;
  cursor: pointer;
  transition: background 0.16s ease;
}

.np-video-item:hover {
  background: var(--np-bg-soft);
}

.np-video-item:hover .np-video-item__thumb img {
  transform: scale(1.06);
}

.np-video-item.is-active {
  background: rgba(34, 113, 177, 0.09);
}

/* 正在播放：左侧竖条比单靠底色更醒目，列表长了也能一眼定位 */
.np-video-item.is-active::before {
  content: '';
  position: absolute;
  left: 0;
  top: 10px;
  bottom: 10px;
  width: 3px;
  border-radius: 2px;
  background: var(--np-primary);
}

.np-video-item.is-active .np-video-item__title {
  color: var(--np-primary);
  font-weight: 600;
}

.np-video-item__thumb {
  position: relative;
  flex: none;
  width: 96px;
  aspect-ratio: 16 / 9;
  border-radius: 7px;
  overflow: hidden;
  background: linear-gradient(135deg, #24303f, #111823);
}

.np-video-item__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.25s ease;
}

.np-video-item__ph {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.82);
  font-size: 18px;
  font-weight: 700;
}

.np-video-item__play {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.88);
  color: #111;
  font-size: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.np-video-item__dur {
  position: absolute;
  right: 4px;
  bottom: 3px;
  padding: 1px 5px;
  border-radius: 3px;
  background: rgba(0, 0, 0, 0.72);
  color: #fff;
  font-size: 10.5px;
  font-variant-numeric: tabular-nums;
}

/* 视频门禁：封面上的「付费可见 / 会员可见」 */
.np-video-item.is-locked .np-video-item__title {
  color: var(--np-text);
}

.np-video-item__lock {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(9, 14, 22, 0.46);
  color: #fff;
}

.np-video-item__lock--vip {
  background: rgba(60, 36, 6, 0.5);
  color: #ffd479;
}

.np-video-item__badge {
  display: inline-block;
  margin-left: 6px;
  padding: 0 5px;
  border-radius: 3px;
  background: rgba(34, 113, 177, 0.12);
  color: var(--np-primary);
  font-size: 10.5px;
  line-height: 16px;
  vertical-align: 1px;
}

.np-video-item__badge--vip {
  background: rgba(214, 154, 20, 0.16);
  color: #8a6100;
}

/* 播放器信息区的访问级别标记 */
.np-video-access-tag {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 1px 7px;
  border-radius: 999px;
  background: rgba(34, 113, 177, 0.12);
  color: var(--np-primary);
  font-size: 11.5px;
  line-height: 18px;
}

.np-video-access-tag--vip {
  background: rgba(214, 154, 20, 0.16);
  color: #8a6100;
}

.np-vlock {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: linear-gradient(135deg, #24303f, #111823);
}

.np-vlock__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(14px) saturate(0.8) brightness(0.6);
  transform: scale(1.08);
}

.np-vlock__grad {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(36, 48, 63, 0.9), rgba(13, 19, 27, 0.95));
}

.np-vlock__body {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 16px;
  text-align: center;
  color: #fff;
}

/* 锁标：直接放大 SVG 本身，不再套圆形底，避免小尺寸下描边发虚。 */
.np-vlock__badge {
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  opacity: 0.92;
}

.np-vlock__badge svg {
  display: block;
}

.np-vlock--vip .np-vlock__badge {
  color: #ffd479;
}

.np-vlock--stage .np-vlock__title {
  font-size: 17px;
}

.np-vlock__title {
  font-size: 15px;
  font-weight: 600;
  line-height: 1.4;
}

.np-vlock__meta {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.78);
}

.np-vlock__acts {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: 2px;
}

/* 缩略图尺寸的锁标（播放列表右侧） */
.np-vlock--thumb .np-vlock__chip {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1px;
  background: rgba(9, 14, 22, 0.46);
  color: #fff;
  font-size: 10px;
  font-style: normal;
  line-height: 1;
}

.np-vlock--thumb .np-vlock__chip svg {
  display: block;
}

.np-vlock--thumb .np-vlock__chip em {
  font-style: normal;
  font-size: 9.5px;
  letter-spacing: 0.02em;
}

/* 列表下方的解锁条 */
.np-vlock-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 12px;
  padding: 10px 14px;
  border: 1px dashed var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg-soft);
}

.np-vlock-bar__text {
  flex: 1 1 auto;
  font-size: 13px;
  color: var(--np-text-2);
}

.np-video-item__body {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.np-video-item__title {
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--np-text);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.np-video-item__group {
  font-size: 12px;
  color: var(--np-muted);
}

.np-video-empty {
  margin-bottom: 56px;
  padding: 48px 24px;
  border: 1px dashed var(--np-line);
  border-radius: 14px;
  text-align: center;
}

.np-video-empty p {
  margin: 0 0 8px;
}

.np-video-empty__tip {
  font-size: 13px;
  color: var(--np-muted);
}

@media (max-width: 1024px) {
  .np-video-layout {
    grid-template-columns: minmax(0, 1fr);
    gap: 18px;
  }

  .np-video-list__items {
    max-height: none;
  }
}

@media (max-width: 600px) {
  .np-video-head {
    margin-bottom: 16px;
    padding: 20px 18px;
    border-radius: 13px;
  }

  .np-video-head__title {
    font-size: 20px;
  }

  .np-video-stage__title {
    font-size: 18px;
  }

  .np-video-stage__frame {
    border-radius: 11px;
  }

  .np-video-stage__nav {
    flex-direction: row;
  }

  .np-video-stage__nav .np-video-nav {
    flex: 1;
    padding: 9px 12px;
    text-align: center;
  }

  /* 手机上列表不再跟随滚动（整页滚就行），限个高度让播放器保持主角地位 */
  .np-video-list {
    position: static;
  }

  /* 手机上列表缩略图放大一号：96px 在 390 宽里只剩指甲盖大小，
   * 看不出画面内容，缩略图就失去意义了。 */
  .np-video-item__thumb {
    width: 124px;
  }

  .np-video-item {
    padding: 9px;
    gap: 12px;
  }

  .np-video-list__items {
    display: grid;
    grid-template-columns: 1fr;
    max-height: 420px;
  }
}

/* --- 文章内视频短代码 --- */
.np-video-embed {
  margin: 1.6em 0;
}

/* 竖屏 / 方形视频在宽正文里会被撑得极高，限制一个最大宽度并居中。 */
.np-video-embed[data-ratio='9 / 16'],
.np-video-embed[data-ratio='1 / 1'],
.np-video-embed[data-ratio='4 / 5'] {
  max-width: 420px;
  margin-left: auto;
  margin-right: auto;
}

.np-video-embed[data-ratio='1 / 1'] {
  max-width: 520px;
}

.np-video-embed__frame,
.np-video-list-wrap .np-video-stage__frame {
  position: relative;
  width: 100%;
  overflow: hidden;
  border-radius: var(--np-radius);
  background: #0b0d12;
}

.np-video-embed__frame iframe,
.np-video-embed__frame video,
.np-video-list-wrap .np-video-stage__frame iframe,
.np-video-list-wrap .np-video-stage__frame video {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
}

/* 「点击后再加载」的封面层：避免一篇文章里多个第三方播放器同时请求。 */
.np-video-embed__cover,
.np-video-stage__cover {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  background: linear-gradient(135deg, #161a23, #0b0d12);
  cursor: pointer;
  overflow: hidden;
}

.np-video-embed__cover img,
.np-video-stage__cover img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.78;
  transition: transform 0.4s ease;
}

.np-video-embed__cover:hover img,
.np-video-stage__cover:hover img {
  transform: scale(1.03);
}

.np-video-embed__grad {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(60% 70% at 22% 78%, rgba(94, 132, 255, 0.32), transparent 70%),
    radial-gradient(50% 60% at 82% 24%, rgba(255, 122, 89, 0.28), transparent 70%);
}

.np-video-embed__play {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.92);
  color: #111;
  font-size: 20px;
  line-height: 1;
  text-indent: 4px;
  box-shadow: 0 8px 26px rgba(0, 0, 0, 0.3);
  transition: transform 0.25s ease;
}

.np-video-embed__cover:hover .np-video-embed__play,
.np-video-stage__cover:hover .np-video-embed__play {
  transform: scale(1.08);
}

.np-video-embed__badge {
  position: absolute;
  left: 14px;
  bottom: 12px;
  z-index: 1;
  max-width: calc(100% - 28px);
  padding: 4px 10px;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.6);
  color: #fff;
  font-size: 12.5px;
  line-height: 1.4;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.np-video-embed__fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  min-height: 120px;
  padding: 20px;
  color: #fff;
  font-size: 14px;
  text-align: center;
  text-decoration: none;
}

.np-video-embed__cap {
  margin-top: 10px;
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--np-muted);
}

.np-video-embed__title {
  display: block;
  margin-bottom: 2px;
  font-weight: 600;
  color: var(--np-text);
}

.np-video-embed__desc {
  display: block;
}

/* 文章内播放列表：沿用视频页的 .np-video-layout，只调整外边距与标题层级。 */
.np-video-list-wrap {
  margin: 1.8em 0;
}

.np-video-list-wrap__title {
  margin: 0 0 14px;
  font-size: 18px;
  font-weight: 700;
}

.np-video-list-wrap--stage .np-video-list {
  display: none;
}

.np-video-list-wrap--stage .np-video-layout {
  display: block;
}

.np-video-list-wrap .np-video-stage__frame {
  aspect-ratio: 16 / 9;
}

.np-video-list-wrap .np-video-list__items {
  max-height: 420px;
  overflow-y: auto;
}

.np-video-list-wrap .np-video-item__link {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  width: 100%;
  padding: 0;
  border: 0;
  background: none;
  font: inherit;
  color: inherit;
  text-align: left;
  cursor: pointer;
}

/* 文章正文里的播放列表：容器较窄，缩略图收一号给文字留空间。 */
.np-entry .np-video-item__thumb {
  width: 84px;
}

.np-entry .np-video-item__body {
  padding-top: 2px;
}

@media (max-width: 640px) {
  .np-video-embed {
    margin: 1.2em 0;
  }

  .np-video-embed__play {
    width: 52px;
    height: 52px;
    font-size: 17px;
  }

  .np-video-embed__badge {
    left: 10px;
    bottom: 10px;
    font-size: 11.5px;
  }

  .np-video-list-wrap {
    margin: 1.4em 0;
  }

  .np-video-list-wrap .np-video-list__items {
    max-height: none;
  }
}

/* --- 数据统计 --- */
.np-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 16px;
  padding: 26px;
  border-radius: var(--np-radius);
  background: var(--np-bg-soft);
  border: 1px solid var(--np-line);
}

.np-stat {
  text-align: center;
}

.np-stat__num {
  font-size: 30px;
  font-weight: 800;
  color: var(--np-primary);
  line-height: 1.2;
}

.np-stat__label {
  font-size: 13px;
  color: var(--np-muted);
  margin-top: 4px;
}

/* --- 侧栏组件：通栏卡（会员推广 / 用户中心 / 站长名片共用） --- */
/* 这三张卡自带完整的视觉体系（渐变头图 / 封面图），widget 的内边距和标题栏
 * 只会碍事，所以整体改成 flush：卡片自己就是整个小工具。 */
.np-widget--flush {
  padding: 0;
  border: 0;
  overflow: hidden;
}

/* flush 卡里没有标题栏，全局 li / ul 的虚线分隔也不要 */
.np-widget--flush li {
  padding: 0;
  border-bottom: 0;
}

/* --- 会员推广卡 --- */
.np-vipcard__hero {
  position: relative;
  padding: 44px 16px 18px;
  background: linear-gradient(135deg, #ff7d59, #ff2d55);
  color: #fff;
  text-align: center;
}

.np-vipcard__tag {
  position: absolute;
  top: 12px;
  left: 12px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 9px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.22);
  font-size: 11.5px;
  font-weight: 600;
}

.np-vipcard__sold {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 3px 9px;
  border-radius: 8px;
  background: rgba(23, 32, 51, 0.75);
  font-size: 11.5px;
  font-variant-numeric: tabular-nums;
}

.np-vipcard__num {
  font-weight: 800;
  line-height: 1.1;
}

.np-vipcard__num strong {
  font-size: 34px;
  letter-spacing: -0.5px;
  font-variant-numeric: tabular-nums;
}

.np-vipcard__cur {
  font-size: 16px;
  margin-right: 2px;
}

.np-vipcard__unit {
  margin-left: 4px;
  font-size: 13px;
  font-weight: 500;
  opacity: 0.92;
}

.np-vipcard__tip {
  display: inline-block;
  margin-top: 10px;
  padding: 4px 12px;
  border-radius: 999px;
  background: rgba(23, 32, 51, 0.45);
  font-size: 12px;
}

.np-vipcard__tiers {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

/* 档位：一高一低才好比价 */
/* 档位：两列网格，月卡 / 季卡 / 年卡 / 永久卡排成两行。
 * 分隔线用「容器铺线色 + 1px gap + 每格铺背景色」画出来：
 * 换成 border 的话，两行布局里只有相邻格有边，行与行之间会缺一条横线。 */
.np-vipcard__tiers {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  background: var(--np-line);
}

.np-vipcard__tier {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 10px 8px 9px;
  background: var(--np-bg);
}

/* 奇数档（只启用 3 档）：最后一格会孤零零占左半行，右边空出的一格
 * 露出来的就是容器的线色背景，看着像一块灰补丁——让它跨满整行。
 * :last-child:nth-child(odd) 正好命中「总数是奇数时的最后一格」。 */
.np-vipcard__tier:last-child:nth-child(odd) {
  grid-column: 1 / -1;
}

.np-vipcard__tier-top {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 5px;
  width: 100%;
}

.np-vipcard__tier-name {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--np-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.np-vipcard__tier-days {
  flex: 0 0 auto;
  font-size: 10.5px;
  color: var(--np-muted);
  font-variant-numeric: tabular-nums;
}

/* 当前所处档位：天数位换成「在用中」，用主色点一下，比再挂角标省地方 */
.np-vipcard__tier.is-owned .np-vipcard__tier-days {
  color: var(--np-primary);
  font-weight: 600;
}

.np-vipcard__tier-price {
  font-size: 15.5px;
  font-weight: 700;
  color: #ff4d5e;
  font-variant-numeric: tabular-nums;
  line-height: 1.25;
}

.np-vipcard__tier-price i {
  margin-right: 1px;
  font-size: 11px;
  font-style: normal;
  font-weight: 600;
}

/* 永久卡：换个颜色，和时长卡一眼分开（买断不是「更长的时长」） */
.np-vipcard__tier.is-perm .np-vipcard__tier-price {
  color: #b45309;
}

.np-vipcard__tier.is-perm .np-vipcard__tier-days {
  color: #b45309;
  font-weight: 600;
}

.np-widget .np-vipcard__srv {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px 12px;
  margin: 0;
  padding: 13px 16px;
  border-top: 1px solid var(--np-line);
}

.np-widget .np-vipcard__srv li {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12.5px;
  color: var(--np-text-2);
}

.np-vipcard__srv svg {
  flex: none;
  color: var(--np-primary);
}

.np-vipcard__cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 2px 16px 16px;
  padding: 11px 0;
  border-radius: 999px;
  background: linear-gradient(90deg, #4facfe, #2563eb);
  color: #fff;
  font-size: 14.5px;
  font-weight: 600;
  text-decoration: none;
  transition: opacity var(--np-transition), transform var(--np-transition);
}

.np-vipcard__cta:hover {
  color: #fff;
  opacity: 0.92;
  transform: translateY(-1px);
}

/* --- 用户名片（原「用户中心卡」+「站长名片」合并） --- */
/* 登录看自己、未登录看站长：一张卡兼顾两种身份，省掉侧栏两张卡的高度。 */
.np-profile__cover {
  position: relative;
  height: 130px;
  background-size: cover;
  background-position: center;
}

/* 没配封面时给一个安静的渐变，别留一片白 */
.np-profile__cover--default {
  background: linear-gradient(135deg, #8ec5fc, #4d6bdb);
}

.np-profile__avatar {
  position: absolute;
  left: 50%;
  bottom: -34px;
  transform: translateX(-50%);
  width: 68px;
  height: 68px;
  border-radius: 50%;
  overflow: hidden;
  box-sizing: border-box;
  border: 3px solid var(--np-bg);
  background: var(--np-bg-soft);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12);
}

.np-profile__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.np-profile__body {
  padding: 42px 18px 18px;
  text-align: center;
}

.np-profile__hi {
  margin: 0;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--np-muted);
  letter-spacing: 0.2px;
}

.np-profile__name {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 4px;
  font-size: 16.5px;
  font-weight: 700;
}

.np-profile__name > a {
  color: var(--np-text);
  text-decoration: none;
}

.np-profile__badge {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 2px 8px;
  border-radius: 999px;
  background: linear-gradient(135deg, #ffd76e, #f59e0b);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
}

.np-profile__badge svg {
  width: 11px;
  height: 11px;
}

.np-profile__follow {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  color: #ff4d5e;
  font-size: 12.5px;
  font-weight: 600;
  text-decoration: none;
}

.np-profile__follow svg {
  width: 13px;
  height: 13px;
  fill: currentColor;
  stroke: none;
}

.np-profile__follow:hover {
  color: #ff2d55;
}

.np-profile__sub {
  margin: 6px 0 0;
  font-size: 12.5px;
  color: var(--np-muted);
}

.np-widget .np-profile__stats {
  display: flex;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
  margin: 12px 0 0;
  padding: 0;
}

.np-widget .np-profile__stats li {
  display: inline-flex;
  align-items: baseline;
  gap: 3px;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 11.5px;
}

.np-profile__stat b {
  font-size: 13px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.np-profile__stat i {
  font-style: normal;
  opacity: 0.78;
}

.np-profile__stat--posts {
  background: color-mix(in srgb, #2563eb 13%, transparent);
  color: #2563eb;
}

.np-profile__stat--comments {
  background: color-mix(in srgb, #16a34a 13%, transparent);
  color: #16a34a;
}

.np-profile__stat--views {
  background: color-mix(in srgb, #ea580c 13%, transparent);
  color: #ea580c;
}

.np-profile__desc {
  margin: 10px 0 0;
  font-size: 12.5px;
  line-height: 1.7;
  color: var(--np-muted);
  text-align: center;
}

/* --- 文章会员卡：汇总本文的付费可见 / 会员可见 / 免费下载 --- */
.np-postcard__tip {
  margin: 0 0 12px;
  font-size: 12.5px;
  line-height: 1.7;
  color: var(--np-muted);
}

.np-postcard__group {
  padding: 12px 14px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg-soft);
}

.np-widget .np-postcard__group + .np-postcard__group {
  margin-top: 10px;
}

.np-postcard__ghead {
  display: flex;
  align-items: center;
  gap: 7px;
}

.np-postcard__gico {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 7px;
  color: #fff;
}

.np-postcard__gname {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--np-text);
}

.np-postcard__gprice {
  padding: 1px 8px;
  border-radius: 999px;
  background: color-mix(in srgb, #f59e0b 16%, transparent);
  color: #d97706;
  font-size: 11.5px;
  font-weight: 700;
}

.np-postcard__gcount {
  margin-left: auto;
  font-size: 11.5px;
  color: var(--np-muted);
  font-variant-numeric: tabular-nums;
}

.np-widget .np-postcard__items {
  list-style: none;
  margin: 9px 0 0;
  padding: 0;
  display: grid;
  gap: 7px;
}

.np-widget .np-postcard__items li {
  margin: 0;
  padding: 0;
  border-bottom: 0;
}

.np-postcard__item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 9px;
  border-radius: 8px;
  background: var(--np-bg);
}

.np-postcard__item-link {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  align-items: baseline;
  gap: 7px;
  text-decoration: none;
}

a.np-postcard__item-link:hover .np-postcard__item-name {
  color: var(--np-primary);
}

.np-postcard__item-name {
  font-size: 13px;
  font-weight: 500;
  color: var(--np-text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.np-postcard__item-meta {
  flex: none;
  font-size: 11px;
  color: var(--np-muted);
}

.np-postcard__tag {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 2px 9px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 600;
}

.np-postcard__tag svg {
  flex: none;
}

.np-postcard__tag.is-lock {
  background: color-mix(in srgb, #ff2d55 12%, transparent);
  color: #ff2d55;
  font-variant-numeric: tabular-nums;
}

.np-postcard__tag.is-ok {
  background: color-mix(in srgb, #16a34a 14%, transparent);
  color: #16a34a;
}

.np-postcard__dl {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--np-primary);
  color: #fff;
  font-size: 11.5px;
  font-weight: 600;
  text-decoration: none;
  transition: opacity var(--np-transition);
}

.np-postcard__dl:hover {
  color: #fff;
  opacity: 0.88;
}

/* 三类用色：付费橙红、会员金、下载蓝 */
.np-postcard__group--pay .np-postcard__gico {
  background: linear-gradient(135deg, #ff7d59, #ff2d55);
}

.np-postcard__group--vip .np-postcard__gico {
  background: linear-gradient(135deg, #ffd76e, #f59e0b);
}

.np-postcard__group--free .np-postcard__gico {
  background: linear-gradient(135deg, #4facfe, #2563eb);
}

.np-postcard__tag.is-need {
  background: color-mix(in srgb, #f59e0b 14%, transparent);
  color: #d97706;
}

/* 解锁入口：主按钮（购买）+ 次按钮（会员） */
.np-postcard__actions {
  display: grid;
  gap: 8px;
  margin-top: 10px;
}

.np-postcard__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 12px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  transition: opacity var(--np-transition);
}

.np-postcard__btn b {
  font-variant-numeric: tabular-nums;
}

.np-postcard__btn--buy {
  background: linear-gradient(90deg, #4facfe, #2563eb);
  color: #fff;
}

.np-postcard__btn--buy:hover {
  color: #fff;
  opacity: 0.9;
}

.np-postcard__btn--vip {
  background: color-mix(in srgb, #f59e0b 14%, transparent);
  color: #d97706;
}

.np-postcard__btn--vip:hover {
  color: #b45309;
}

/* 卡内条目点击后滚动定位，留出让吸顶导航遮挡的余量 */
.np-locked,
.np-download {
  scroll-margin-top: 90px;
}

.np-profile__btns {
  display: flex;
  gap: 10px;
  margin-top: 14px;
}

.np-profile__btn {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 9px 0;
  border-radius: 8px;
  color: #fff;
  font-size: 13.5px;
  font-weight: 600;
  text-decoration: none;
  transition: opacity var(--np-transition);
}

.np-profile__btn:hover {
  color: #fff;
  opacity: 0.9;
}

.np-profile__btn--go {
  background: linear-gradient(135deg, #4facfe, #2563eb);
}

.np-profile__btn--alt {
  background: linear-gradient(135deg, #ffab40, #ff6d00);
}

/* 通栏卡上方若填了标题，贴着卡片走，不要留出 widget 的标题留白 */
.np-widget--flush .np-widget__title {
  margin: 0;
  padding: 12px 16px 0;
}

.np-sidebar-empty {
  margin: 0;
  font-size: 13px;
  line-height: 1.8;
  color: var(--np-muted);
}

/* --- 侧栏组件：活跃作者 --- */
.np-users {
  display: grid;
  gap: 7px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.np-user__link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 9px;
  border: 1px solid transparent;
  border-radius: var(--np-radius-sm);
  text-decoration: none;
  transition: border-color var(--np-transition), background var(--np-transition);
}

.np-user__link:hover {
  border-color: color-mix(in srgb, var(--np-primary) 35%, transparent);
  background: var(--np-primary-soft);
}

/* 名次：有榜就有先后，比单纯罗列更好扫 */
.np-user__rank {
  flex: none;
  width: 16px;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  color: var(--np-muted);
  text-align: center;
}

.np-users li:nth-child(-n + 3) .np-user__rank {
  color: var(--np-primary);
  font-weight: 700;
}

/* 侧栏 .np-widget 给 li 加了虚线分隔与内边距，作者榜自己有卡片样式，别叠两层 */
.np-widget .np-users li {
  padding: 0;
  border-bottom: 0;
}

.np-user__avatar {
  flex: none;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  overflow: hidden;
  background: var(--np-bg-soft);
}

.np-user__img {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: block;
}

.np-user__body {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.np-user__name {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--np-text);
}

.np-user__desc {
  font-size: 12px;
  color: var(--np-muted);
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
}

.np-user__count {
  margin-left: auto;
  flex: none;
  font-size: 12px;
  color: var(--np-muted);
  font-variant-numeric: tabular-nums;
}

/* --- 侧栏组件：文章日历 --- */
.np-cal {
  padding: 12px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg);
}

.np-cal__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 10px;
}

.np-cal__title {
  font-size: 14px;
  font-weight: 600;
  color: var(--np-text);
}

.np-cal__nav {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border: 1px solid var(--np-line);
  border-radius: 50%;
  font-size: 15px;
  line-height: 1;
  color: var(--np-text-2);
  text-decoration: none;
  transition: color var(--np-transition), border-color var(--np-transition);
}

.np-cal__nav:hover {
  color: var(--np-primary);
  border-color: var(--np-primary);
}

.np-cal__grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 3px;
}

.np-cal__weekday {
  padding: 3px 0;
  text-align: center;
  font-size: 11.5px;
  color: var(--np-muted);
}

.np-cal__cell {
  aspect-ratio: 1 / 1;
}

.np-cal__cell.is-empty {
  visibility: hidden;
}

.np-cal__day {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1px;
  width: 100%;
  height: 100%;
  border-radius: 6px;
  font-size: 12px;
  color: var(--np-text-2);
  text-decoration: none;
  transition: background var(--np-transition), color var(--np-transition);
}

.np-cal__day.is-empty {
  color: var(--np-muted);
  opacity: 0.5;
}

.np-cal__cell.has-posts .np-cal__day {
  background: var(--np-primary-soft);
  color: var(--np-primary);
  font-weight: 600;
}

.np-cal__cell.has-posts .np-cal__day:hover {
  background: var(--np-primary);
  color: #fff;
}

.np-cal__cell.is-today .np-cal__day {
  box-shadow: inset 0 0 0 1px var(--np-primary);
}

/* 当天有文章时用一个小圆点标出来，比数字更轻 */
.np-cal__dot {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: currentColor;
}

.np-cal__empty {
  margin: 10px 0 0;
  font-size: 12px;
  color: var(--np-muted);
  text-align: center;
}

/* 模块空状态提示 */
.np-module__empty {
  margin: 0;
  padding: 18px;
  border: 1px dashed var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg-soft);
  font-size: 13px;
  color: var(--np-muted);
  text-align: center;
}

/* --- 广告位 --- */
.np-ad {
  border-radius: var(--np-radius);
  overflow: hidden;
}

.np-ad__img {
  width: 100%;
  border-radius: var(--np-radius);
}

.np-ad__code {
  padding: 14px;
  border: 1px dashed var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg-soft);
  text-align: center;
  font-size: 13px;
  color: var(--np-muted);
}

/* --- 备案信息 --- */
.np-icp {
  font-size: 13.5px;
  color: var(--np-text-2);
}

.np-icp__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.np-icp__item {
  display: flex;
  align-items: center;
  gap: 10px;
}

.np-icp a {
  color: var(--np-text-2);
}

.np-icp a:hover {
  color: var(--np-primary);
}

.np-icp__label {
  color: var(--np-muted);
  font-size: 13px;
}

.np-icp__value {
  font-weight: 600;
  color: var(--np-text);
}

.np-icp--inline .np-icp__item + .np-icp__item {
  padding-left: 14px;
  border-left: 1px solid var(--np-line);
}

.np-icp--block .np-icp__list {
  display: grid;
  gap: 10px;
}

.np-icp--block .np-icp__item {
  justify-content: space-between;
  padding: 10px 14px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg-soft);
}

.np-icp--card {
  padding: 20px 22px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg-soft);
}

.np-icp__head {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 14px;
  font-size: 15px;
  font-weight: 700;
  color: var(--np-text);
}

.np-icp__shield {
  display: inline-flex;
  width: 28px;
  height: 28px;
  border-radius: 9px;
  background: var(--np-primary-soft);
  color: var(--np-primary);
  align-items: center;
  justify-content: center;
}

.np-icp--card .np-icp__list {
  display: grid;
  gap: 10px;
}

.np-icp--card .np-icp__item {
  justify-content: space-between;
  padding-bottom: 9px;
  border-bottom: 1px dashed var(--np-line);
}

.np-icp--card .np-icp__item:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.np-icp__extra {
  margin: 12px 0 0;
  font-size: 12.5px;
  line-height: 1.75;
  color: var(--np-muted);
}

/* --- 备案胶囊（页脚默认） ---
 * 备案号天生又长又没重点，直接一行排开会被读成「一串灰字」。
 * 做成胶囊后每一条有边界、有图标、可点，扫一眼就知道有几项、分别是什么；
 * 图标统一用 currentColor，胶囊 hover 时图标跟着一起变色。 */
.np-icp--chip .np-icp__list {
  gap: 8px;
  justify-content: center;
}

.np-icp--chip .np-icp__item {
  padding: 0;
  border: 0;
}

.np-icp__chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  max-width: 100%;
  padding: 6px 13px;
  border: 1px solid var(--np-line);
  border-radius: 999px;
  background: var(--np-bg);
  color: var(--np-text-2);
  font-size: 12.5px;
  line-height: 1.45;
  text-decoration: none;
  transition: color var(--np-transition), border-color var(--np-transition), background var(--np-transition);
}

.np-icp__chip:hover {
  color: var(--np-primary);
  border-color: color-mix(in srgb, var(--np-primary) 42%, transparent);
  background: var(--np-primary-soft);
}

.np-icp--chip .np-icp__label {
  font-size: 12px;
  color: var(--np-muted);
}

.np-icp--chip .np-icp__value {
  font-weight: 500;
}

.np-icp__icon {
  display: inline-flex;
  align-items: center;
  flex: none;
  font-size: 14px;
  color: var(--np-muted);
  transition: color var(--np-transition);
}

.np-icp__icon svg {
  width: 1em;
  height: 1em;
  display: block;
}

.np-icp__chip:hover .np-icp__icon,
.np-icp__item:hover .np-icp__icon {
  color: currentColor;
}

/* block / card 样式里图标贴在类型名前面，跟胶囊一样留 6px 呼吸 */
.np-icp--block .np-icp__label,
.np-icp--card .np-icp__label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

/* 自定义图标可能是任意比例的位图，按 1em 兜住，别把胶囊撑变形。 */
.np-icp__img {
  display: block;
  width: 1em;
  height: 1em;
  object-fit: contain;
}

.np-footer__icp {
  padding: 6px 0 0;
}

.np-footer__icp .np-icp {
  font-size: 12.5px;
  color: var(--np-muted);
}

.np-footer__icp a {
  color: var(--np-muted);
}

.np-footer__icp a:hover {
  color: var(--np-primary);
}

/* --- 手机底部导航栏 --- */
.np-mnav {
  display: none;
}

/* 底部导航固定在屏幕底部，会盖住页面最后一屏内容（页脚的备案号、最后一篇文章）。
 * 这里给 body 兜一层 padding，再由下面的 .np-site 抵消——只靠 .np-site 的 padding
 * 不够：.np-footer 自带 margin，margin 折叠后把 padding 吃掉了一部分。
 * 另外 iOS 的 safe-area 也要算进去，否则 iPhone 底部横条会压住「首页」。
 * --np-mnav-h 由底栏自身高度决定，改高度只要改这一个变量。 */
:root {
  --np-mnav-h: 56px;
}

body.np-mnav-on {
  padding-bottom: calc(var(--np-mnav-h) + env(safe-area-inset-bottom, 0px) + 8px);
}

@media (max-width: 768px) {
  body.np-mnav-on .np-site {
    padding-bottom: calc(var(--np-mnav-h) + env(safe-area-inset-bottom, 0px));
  }

  /* 页脚本来靠 margin 与正文拉开距离，二者叠加会多出一段空白；
     取消 margin 后由 .np-site 的 padding 统一兜住。 */
  body.np-mnav-on .np-footer {
    margin-bottom: 0;
  }

  .np-mnav {
    display: flex;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 80;
    height: calc(56px + env(safe-area-inset-bottom, 0px));
    padding-bottom: env(safe-area-inset-bottom, 0px);
    background: color-mix(in srgb, var(--np-bg) 94%, transparent);
    backdrop-filter: saturate(180%) blur(10px);
    border-top: 1px solid var(--np-line);
  }

  /* 滚动时收起底部菜单栏：整条往下位移滑出屏幕。
     用 transform 而不是改 bottom / display——transform 不触发重排，
     body 为底栏预留的 padding 也保持不变，收起时正文不会突然被拉长一截。 */
  .np-mnav--autohide {
    transition: transform 0.28s cubic-bezier(0.32, 0.72, 0, 1);
    will-change: transform;
  }

  .np-mnav.is-hidden {
    transform: translateY(100%);
  }

  /* 抽屉打开时底栏保持原位，理由同顶部导航 */
  body.np-drawer-on .np-mnav {
    transform: none;
  }

  /* 底栏收起后，「返回顶部」跟着落到屏幕角上，
     否则右下角会空出一块底栏的高度，看着像少了东西。 */
  body.np-bars-hidden .np-fab {
    bottom: calc(18px + env(safe-area-inset-bottom, 0px));
  }

  .np-mnav__item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    font-size: 11px;
    color: var(--np-muted);
    -webkit-tap-highlight-color: transparent;
  }

  .np-mnav__item.is-active {
    color: var(--np-primary);
  }

  .np-mnav__icon {
    display: flex;
    align-items: center;
  }

  /* 底部导航出现时，悬浮组整体抬高到导航栏之上 */
  /* 悬浮组要避开底部导航：抬高到导航之上，并且只留返回顶部一个按钮，
     明暗在抽屉里也有入口，不必在右下角再占一个。 */
  .np-fab {
    bottom: calc(var(--np-mnav-h) + env(safe-area-inset-bottom, 0px) + 16px);
    right: 14px;
    gap: 8px;
    transition: bottom 0.28s cubic-bezier(0.32, 0.72, 0, 1);
  }

  /* 手机：底部导航右侧已有「会员」，明暗按钮也进抽屉，
     再放一个圆形按钮会正好压住会员图标——这里只留「返回顶部」一个。 */
  .np-fab .np-fab__dark {
    display: none;
  }

  body:not(.np-mnav-on) .np-fab {
    bottom: calc(18px + env(safe-area-inset-bottom, 0px));
  }
}

/* --- 会员：登录注册 / 用户中心 --- */
.np-auth {
  display: flex;
  justify-content: center;
  padding: 46px 0 60px;
}

.np-auth__card {
  width: 100%;
  max-width: 420px;
  padding: 34px 34px 30px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
  box-shadow: var(--np-shadow);
}

.np-auth__brand {
  text-align: center;
  margin-bottom: 22px;
}

.np-auth__logo {
  display: inline-flex;
  align-items: center;
  font-size: 22px;
  font-weight: 800;
  color: var(--np-text);
  text-decoration: none;
}
/* 1.8.35：登录页 Logo 也跟随「站点身份」里的尺寸滑块，手机端单独一档。 */
.np-auth__logo-img {
  display: block;
  width: auto;
  height: auto;
  max-height: calc(var(--np-logo-h, 40px) * 1.1);
  max-width: min(calc(var(--np-logo-h, 40px) * 4.5), 240px);
  object-fit: contain;
}

.np-auth__sub {
  margin: 8px 0 0;
  font-size: 13px;
  color: var(--np-muted);
}

.np-auth__tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 22px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg-soft);
  padding: 4px;
}

.np-auth__tab {
  flex: 1;
  text-align: center;
  padding: 8px 0;
  border-radius: var(--np-radius-sm);
  font-size: 14px;
  font-weight: 600;
  color: var(--np-text-2);
}

.np-auth__tab.is-active {
  background: var(--np-bg);
  color: var(--np-primary);
  box-shadow: var(--np-shadow);
}

.np-auth__title {
  margin: 0 0 16px;
  font-size: 19px;
}

.np-auth__tip {
  margin: 0 0 16px;
  font-size: 13.5px;
  color: var(--np-text-2);
}

.np-auth__msg {
  padding: 10px 14px;
  margin-bottom: 16px;
  border-radius: var(--np-radius-sm);
  font-size: 13.5px;
}

.np-auth__msg--ok {
  background: rgba(0, 163, 42, 0.1);
  color: #00a32a;
}

.np-auth__msg--err {
  background: rgba(214, 54, 54, 0.1);
  color: var(--np-accent);
}

.np-form-row {
  margin-bottom: 14px;
}

.np-form-row label {
  display: block;
  margin-bottom: 6px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--np-text);
}

.np-form-row input[type='text'],
.np-form-row input[type='email'],
.np-form-row input[type='password'],
.np-form-row input[type='url'],
.np-form-row textarea {
  width: 100%;
  height: 40px;
  padding: 0 12px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg);
  color: var(--np-text);
  font-size: 14px;
  outline: none;
  transition: var(--np-transition);
}

.np-form-row textarea {
  height: auto;
  padding: 10px 12px;
  line-height: 1.6;
  resize: vertical;
}

.np-form-row input:focus,
.np-form-row textarea:focus {
  border-color: var(--np-primary);
  box-shadow: 0 0 0 3px var(--np-primary-soft);
}

.np-form-row--check {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13.5px;
  font-weight: 400;
  color: var(--np-text-2);
}

.np-form-row--check input {
  width: 15px;
  height: 15px;
}

.np-auth__submit {
  width: 100%;
  margin-top: 6px;
}

.np-auth__alt {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin: 16px 0 0;
  font-size: 13px;
}

.np-auth__alt a {
  color: var(--np-muted);
}

.np-auth__alt a:hover {
  color: var(--np-primary);
}

.np-form-hint {
  margin: 6px 0 0;
  font-size: 12.5px;
  color: var(--np-muted);
}

/* 用户中心 */
.np-account {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: var(--np-gap);
  padding: 36px 0 60px;
  align-items: start;
}

.np-account__card {
  padding: 24px;
  margin-bottom: var(--np-gap);
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
}

.np-account__card:last-child {
  margin-bottom: 0;
}

.np-account__me {
  text-align: center;
}

.np-account__avatar {
  display: inline-flex;
  width: 88px;
  height: 88px;
  border-radius: 50%;
  overflow: hidden;
  border: 3px solid var(--np-primary-soft);
}

.np-account__avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.np-account__name {
  margin: 12px 0 2px;
  font-size: 18px;
}

.np-account__email {
  margin: 0;
  font-size: 13px;
  color: var(--np-muted);
  word-break: break-all;
}

.np-account__role {
  display: inline-block;
  margin-top: 10px;
  padding: 2px 10px;
  border-radius: 999px;
  background: var(--np-primary-soft);
  color: var(--np-primary);
  font-size: 12px;
  font-weight: 600;
}

.np-account__meta {
  margin: 16px 0 0;
  display: grid;
  gap: 8px;
  text-align: left;
}

.np-account__meta > div {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
}

.np-account__meta dt {
  color: var(--np-muted);
}

.np-account__meta dd {
  margin: 0;
  font-weight: 600;
}

.np-account__logout {
  width: 100%;
  margin-top: 18px;
  color: var(--np-accent);
  border-color: var(--np-accent);
}

.np-account__logout:hover {
  background: rgba(214, 54, 54, 0.08);
  color: var(--np-accent);
  border-color: var(--np-accent);
}

.np-account__cardtitle {
  margin: 0 0 16px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--np-line);
  font-size: 15.5px;
}

.np-account__hint {
  margin: 0;
  font-size: 13px;
  line-height: 1.7;
  color: var(--np-muted);
}

.np-account__avatarlink {
  display: inline-block;
  margin-top: 10px;
  font-size: 13px;
  color: var(--np-primary);
}

.np-account__comments {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 14px;
}

.np-account__comments li {
  padding-bottom: 12px;
  border-bottom: 1px dashed var(--np-line);
}

.np-account__comments li:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.np-account__commenttext {
  font-size: 14px;
  color: var(--np-text);
  line-height: 1.7;
}

.np-account__commentmeta {
  margin-top: 6px;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 12px;
  font-size: 12.5px;
  color: var(--np-muted);
}

.np-account__commentmeta a {
  color: var(--np-text-2);
}

.np-account__commentmeta a:hover {
  color: var(--np-primary);
}

@media (max-width: 768px) {
  .np-auth {
    padding: 24px 0 40px;
  }

  .np-auth__card {
    padding: 24px 20px;
  }

  .np-account {
    grid-template-columns: minmax(0, 1fr);
    padding: 20px 0 40px;
  }
}

/* ==========================================================================
   5. 归档 / 单篇
   ========================================================================== */
.np-archive-head {
  padding: 22px 24px;
  margin-bottom: var(--np-gap);
  border-radius: var(--np-radius);
  background: var(--np-bg-soft);
  border: 1px solid var(--np-line);
}

.np-archive-head h1 {
  margin: 0 0 6px;
  font-size: 24px;
}

.np-archive-head p {
  margin: 0;
  color: var(--np-text-2);
  font-size: 14px;
}

.np-breadcrumb {
  font-size: 13px;
  color: var(--np-muted);
  margin-bottom: 14px;
}

.np-breadcrumb a:hover {
  color: var(--np-primary);
}

.np-breadcrumb__sep {
  margin: 0 6px;
  opacity: 0.6;
}

.np-single {
  max-width: none;
}

.np-single__header {
  margin-bottom: 22px;
}

.np-single__title {
  font-size: 30px;
  line-height: 1.35;
  margin: 0 0 14px;
}

.np-single__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--np-line);
  font-size: 13px;
  color: var(--np-muted);
}

.np-single__cats a {
  padding: 2px 9px;
  border-radius: 4px;
  background: var(--np-primary-soft);
  color: var(--np-primary);
  font-weight: 600;
  font-size: 12.5px;
}

.np-entry {
  font-size: 15.5px;
  line-height: 1.85;
  color: var(--np-text);
}

.np-entry > *:last-child {
  margin-bottom: 0;
}

.np-entry img {
  border-radius: var(--np-radius);
}

.np-entry h2,
.np-entry h3 {
  margin-top: 30px;
  padding-left: 11px;
  border-left: 3px solid var(--np-primary);
}

.np-entry ul,
.np-entry ol {
  margin: 0 0 16px;
  padding-left: 24px;
}

.np-entry li {
  margin-bottom: 6px;
}

.np-entry table {
  font-size: 14px;
}

.np-entry th {
  background: var(--np-bg-soft);
  font-weight: 600;
}

.np-entry hr {
  margin: 26px 0;
  border: 0;
  border-top: 1px solid var(--np-line);
}

.np-entry iframe,
.np-entry embed,
.np-entry video {
  max-width: 100%;
}

/* 经典编辑器「格式」下拉产出的样式 */
.np-entry .np-lead {
  font-size: 17px;
  color: var(--np-text-2);
}

.np-entry .np-note {
  padding: 12px 16px;
  margin: 0 0 16px;
  border-left: 3px solid var(--np-accent);
  background: var(--np-primary-soft);
  border-radius: 0 var(--np-radius-sm) var(--np-radius-sm) 0;
  font-size: 14.5px;
}

.np-entry img.alignleft,
.np-entry img.alignright {
  max-width: 50%;
  height: auto;
}

.np-entry .wp-caption-text,
.np-entry figcaption {
  text-align: center;
  font-size: 13px;
  color: var(--np-muted);
  margin-top: 6px;
}

.np-single__footer {
  margin-top: 26px;
  padding-top: 20px;
  border-top: 1px solid var(--np-line);
}

.np-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.np-tag {
  padding: 3px 11px;
  border: 1px solid var(--np-line);
  border-radius: 999px;
  font-size: 12.5px;
  color: var(--np-text-2);
}

.np-tag:hover {
  border-color: var(--np-primary);
  color: var(--np-primary);
}

.np-author-box {
  display: flex;
  gap: 16px;
  padding: 20px;
  margin-top: 24px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg-soft);
}

.np-author-box__avatar {
  flex: none;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  object-fit: cover;
}

.np-author-box__name {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 4px;
}

.np-author-box__desc {
  font-size: 14px;
  color: var(--np-text-2);
  margin-bottom: 8px;
}

.np-post-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-top: 24px;
}

.np-post-nav__item {
  padding: 14px 16px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  font-size: 14px;
}

.np-post-nav__item span {
  display: block;
  font-size: 12px;
  color: var(--np-muted);
  margin-bottom: 4px;
}

.np-post-nav__item--next {
  text-align: right;
}

.np-related {
  margin-top: 36px;
}

/* ==========================================================================
   6. 侧栏与小工具
   ========================================================================== */
.np-sidebar-col {
  display: flex;
  flex-direction: column;
  gap: 20px;
  position: sticky;
  top: calc(var(--np-header-h) + 20px);
}

.np-widget {
  padding: 18px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
}

.np-widget__title {
  margin: 0 0 14px;
  font-size: 16px;
  padding-bottom: 9px;
  border-bottom: 1px solid var(--np-line);
  display: flex;
  align-items: center;
  gap: 8px;
}

.np-widget__title::before {
  content: '';
  width: 3px;
  height: 15px;
  border-radius: 2px;
  background: var(--np-primary);
}

.np-widget ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.np-widget li {
  padding: 6px 0;
  font-size: 14px;
  border-bottom: 1px dashed var(--np-line);
}

.np-widget li:last-child {
  border-bottom: 0;
}

.np-widget select,
.np-widget input[type='search'] {
  width: 100%;
  height: 34px;
  padding: 0 10px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg);
  color: var(--np-text);
}

.np-tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

/* 侧栏广告位 */
.np-adbox {
  position: relative;
  padding: 0;
  overflow: hidden;
}

.np-adbox__tag {
  position: absolute;
  top: 6px;
  right: 6px;
  z-index: 2;
  padding: 1px 6px;
  border-radius: 3px;
  background: rgba(0, 0, 0, 0.42);
  color: #fff;
  font-size: 10px;
  line-height: 16px;
  letter-spacing: 0.04em;
  pointer-events: none;
}

.np-adbox__link,
.np-adbox__img {
  display: block;
  width: 100%;
}

.np-adbox__img {
  height: auto;
  border-radius: var(--np-radius);
}

.np-adbox__text {
  display: block;
  padding: 22px 16px;
  text-align: center;
  font-size: 14px;
  font-weight: 500;
  color: var(--np-text-2);
  background: var(--np-bg-soft);
  border-radius: var(--np-radius);
}

.np-adbox__html {
  padding: 0;
}

.np-adbox__html > *:first-child {
  margin-top: 0;
}

.np-adbox__html > *:last-child {
  margin-bottom: 0;
}

/* 空广告位不留白框 */
.np-adbox:empty {
  display: none;
}

/* ==========================================================================
   7. 分页 & 评论
   ========================================================================== */
.np-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: 32px;
  flex-wrap: wrap;
}

.np-pagination .page-numbers,
.np-pagination a,
.np-pagination span {
  min-width: 36px;
  height: 36px;
  padding: 0 11px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  font-size: 14px;
  color: var(--np-text-2);
}

.np-pagination .current {
  background: var(--np-primary);
  border-color: var(--np-primary);
  color: #fff;
  font-weight: 600;
}

.np-pagination a:hover {
  border-color: var(--np-primary);
  color: var(--np-primary);
}

.np-comments {
  margin-top: 40px;
}

.np-comments__title {
  font-size: 19px;
  margin-bottom: 18px;
}

.np-comment-list {
  list-style: none;
  margin: 0 0 24px;
  padding: 0;
}

.np-comment-list .children {
  list-style: none;
  padding-left: 26px;
  margin: 0;
}

.np-comment {
  padding: 14px 0;
  border-bottom: 1px solid var(--np-line);
}

.np-comment__meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
  font-size: 13px;
}

.np-comment__avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
}

.np-comment__author {
  font-weight: 600;
}

.np-comment__date {
  color: var(--np-muted);
  font-size: 12.5px;
}

.np-comment__text {
  font-size: 14.5px;
  color: var(--np-text-2);
}

.np-comment-form input,
.np-comment-form textarea {
  width: 100%;
  padding: 9px 12px;
  margin-bottom: 12px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg);
  color: var(--np-text);
  font-size: 14px;
  font-family: inherit;
}

.np-comment-form textarea {
  min-height: 108px;
  resize: vertical;
}

.np-comment-form input:focus,
.np-comment-form textarea:focus {
  border-color: var(--np-primary);
  outline: none;
}

.np-comment-note {
  font-size: 13px;
  color: var(--np-muted);
  margin-bottom: 12px;
}

/* ==========================================================================
   8. 页脚
   ========================================================================== */
.np-footer {
  margin-top: 56px;
  padding: 44px 0 0;
  border-top: 1px solid var(--np-line);
  background: var(--np-bg-soft);
  font-size: 14px;
  color: var(--np-text-2);
}

.np-footer a {
  color: inherit;
  text-decoration: none;
  transition: color var(--np-transition);
}

/* --- 内置布局：品牌区 + 两列链接 --- */
.np-footer__main {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr) minmax(0, 1fr);
  gap: 48px;
  padding-bottom: 36px;
}

.np-footer__logo {
  display: inline-block;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--np-text);
}

.np-footer__logo:hover {
  color: var(--np-primary);
}

.np-footer__logo-img {
  display: block;
  max-height: 36px;
  width: auto;
}

.np-footer__desc {
  margin: 12px 0 0;
  max-width: 34em;
  font-size: 14px;
  line-height: 1.75;
  color: var(--np-muted);
}

/* 统计三格：数字大、单位小，横向一排不占高度，把品牌区的空白填实 */
/* 三格等宽：以前用 flex + 固定间距，列宽随内容长短变，三项看着像随便排的。
 * 等宽三列之后，三个数字的起始位置和单位行都在同一条竖线上。 */
.np-footer__stats {
  display: grid;
  /* 列数跟着条目数走，等宽均分：站点还没有文章时只有两格，也不会空出半排。 */
  grid-auto-flow: column;
  grid-auto-columns: minmax(0, 1fr);
  gap: 0 14px;
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
}

.np-footer__stats li {
  display: flex;
  align-items: baseline;
  gap: 5px;
  min-width: 0;
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--np-muted);
}

/* 单位那截允许换行但不断词，列窄的时候往下走而不是把列撑开 */
.np-footer__stats li span {
  min-width: 0;
  overflow-wrap: break-word;
}

.np-footer__stats strong {
  font-size: 17px;
  font-weight: 600;
  line-height: 1.2;
  color: var(--np-text);
  font-variant-numeric: tabular-nums;
}

/* 社交入口：文字胶囊比两个字的圆点信息量大，也更好点 */
.np-footer__social {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.np-footer__social a,
.np-footer__social button {
  display: inline-flex;
  align-items: center;
  height: 30px;
  padding: 0 12px;
  border: 1px solid var(--np-line);
  border-radius: 999px;
  background: var(--np-bg);
  font-size: 13px;
  font-family: inherit;
  line-height: 1;
  color: var(--np-muted);
  cursor: pointer;
  transition: color var(--np-transition), border-color var(--np-transition);
}

.np-footer__social a:hover,
.np-footer__social button:hover {
  border-color: var(--np-primary);
  color: var(--np-primary);
}

.np-footer__title {
  margin: 0 0 14px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--np-text);
}

.np-footer__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.np-footer__list a {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 6px;
  padding: 5px 0;
  font-size: 14px;
  color: var(--np-text-2);
}

.np-footer__list a:hover {
  color: var(--np-primary);
}

.np-footer__list-text {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* 计数胶囊：复用分类卡的克制感，不抢链接本身的注意力 */
.np-footer__count {
  flex: none;
  min-width: 22px;
  padding: 0 6px;
  font-size: 11.5px;
  line-height: 18px;
  text-align: center;
  color: var(--np-muted);
  background: var(--np-bg);
  border: 1px solid var(--np-line);
  border-radius: 999px;
  font-variant-numeric: tabular-nums;
}

.np-footer__empty {
  margin: 0;
  font-size: 13.5px;
  color: var(--np-muted);
}

/* --- 小工具布局（老用户配过 sidebar 时） --- */
.np-footer__widgets {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 28px;
  padding-bottom: 30px;
}

.np-footer__widgets .np-widget {
  padding: 0;
  border: 0;
  background: none;
}

.np-footer__widgets .np-widget__title {
  margin-bottom: 12px;
  padding-bottom: 0;
  border-bottom: 0;
  font-size: 13px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--np-text);
}

.np-footer__widgets .np-widget__title::before {
  display: none;
}

.np-footer__widgets .np-widget li {
  padding: 4px 0;
  border-bottom: 0;
  font-size: 14px;
  color: var(--np-text-2);
}

/* --- 底栏 --- */
/* 页脚里的备案信息不用组件默认的竖线：竖线在窄屏换行时会留下一段悬空的线头。
 * 宽屏靠间距分隔，窄屏干脆一列一列排，比中点、比竖线都干净。 */
.np-footer__icp .np-icp--inline {
  padding: 0;
}

.np-footer__icp .np-icp--inline .np-icp__list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 18px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.np-footer__icp .np-icp--inline .np-icp__item {
  padding: 0;
  border: 0;
  gap: 6px;
}

.np-footer__icp .np-icp--inline .np-icp__item + .np-icp__item {
  padding-left: 0;
  border-left: 0;
}

/* 卡片样式在页脚里太占地方，收掉外框，只留内容本身。 */
.np-footer__icp .np-icp--card {
  padding: 14px 16px;
}

.np-footer__bottom {
  margin-top: 16px;
  padding: 14px 0 22px;
  border-top: 1px solid var(--np-line);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 24px;
  font-size: 13px;
  color: var(--np-muted);
}

.np-footer__copy {
  min-width: 0;
}

.np-footer__nav {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 18px;
}

.np-footer__nav a {
  color: var(--np-muted);
}

.np-footer__nav a:hover {
  color: var(--np-primary);
}

/* 右下悬浮操作组：手机上「明暗切换 + 返回顶部」叠成一列。
 * 以前返回顶部自己 fixed 在右下，明暗按钮挤在头部；
 * 合成一组后两者共用一条竖线，不会互相错位。 */
.np-fab {
  position: fixed;
  right: 18px;
  bottom: 22px;
  z-index: 82;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.np-fab__btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 1px solid var(--np-line);
  border-radius: 50%;
  background: var(--np-bg);
  color: var(--np-text-2);
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(9, 14, 22, 0.12);
  transition: var(--np-transition);
  -webkit-tap-highlight-color: transparent;
}

.np-fab__btn:active {
  transform: scale(0.94);
}

/* 深色模式下按太阳/月亮切换图标 */
.np-fab__dark .np-fab__icon--sun {
  display: none;
}

body.np-dark .np-fab__dark .np-fab__icon--sun {
  display: block;
}

body.np-dark .np-fab__dark .np-fab__icon--moon {
  display: none;
}

body.np-dark .np-fab__dark {
  color: #f5d76e;
}

.np-backtop {
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 50%;
  background: var(--np-primary);
  color: #fff;
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 14px color-mix(in srgb, var(--np-primary) 32%, transparent);
}

/* 桌面上悬浮组不需要明暗按钮（头部已有），只显示返回顶部 */
@media (min-width: 769px) {
  .np-fab .np-fab__dark {
    display: none;
  }
}

.np-backtop.is-visible {
  display: flex;
}

/* ==========================================================================
   9. 404 / 搜索空态
   ========================================================================== */
.np-empty {
  text-align: center;
  padding: 70px 20px;
}

.np-empty__code {
  font-size: 76px;
  font-weight: 800;
  color: var(--np-primary);
  line-height: 1;
  margin-bottom: 10px;
}

.np-empty p {
  color: var(--np-text-2);
  margin-bottom: 20px;
}

/* ==========================================================================
   10. 响应式
   ========================================================================== */
@media (max-width: 1100px) {
  :root {
    --np-sidebar: 280px;
  }
}

@media (max-width: 960px) {
  /* 页脚：三栏压成两栏，品牌区独占一行——窄屏下硬塞三列会把链接挤成省略号 */
  .np-footer__main {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 32px 40px;
  }

  .np-footer__brand {
    grid-column: 1 / -1;
  }

  .np-layout,
  .np-layout--left {
    grid-template-columns: minmax(0, 1fr);
  }

  .np-layout--left .np-content,
  .np-layout--left .np-sidebar-col {
    order: initial;
  }

  .np-sidebar-col {
    position: static;
  }

  .np-post-grid,
  .np-video-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  /* 手机头部：汉堡在左、站名居中、操作区靠右。
   * 站名用绝对定位居中，不被两侧宽度差挤歪。 */
  .np-header__inner {
    position: relative;
    justify-content: space-between;
  }

  .np-menu-toggle {
    display: inline-flex;
    order: 0;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border: 1px solid var(--np-line);
    border-radius: var(--np-radius-sm);
    background: transparent;
    cursor: pointer;
    color: var(--np-text);
  }

  .np-brand {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    margin: 0;
    /* 1.8.35：原来 46% 太窄，Logo + 标题必然互相挤压；放宽上限并允许
       收缩省略，配合手机端单独的 Logo 尺寸滑块，横版长图也不会把站名挤没。 */
    max-width: min(56%, 240px);
    min-width: 0;
    overflow: hidden;
    justify-content: center;
  }

  .np-brand .np-brand__link { max-width: 100%; }

  .np-header__actions {
    order: 2;
    margin-left: auto;
  }

  /* 导航改为抽屉：从屏幕左缘滑入，点汉堡往右弹出。
   *
   * 层级必须高于 .np-mnav（80）和 .np-backtop，且不能待在 .np-header 里——
   * 头部是 sticky + backdrop-filter，会创建层叠上下文，之前抽屉的 z-index:90
   * 反而被底部导航盖住。JS 会把 .np-nav 搬到 body 下，这里只是纯视觉。 */
  .np-nav {
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    z-index: 96;
    width: min(304px, 82vw);
    padding: 0 0 calc(18px + env(safe-area-inset-bottom, 0px));
    background: var(--np-bg);
    box-shadow: 0 0 60px rgba(9, 14, 22, 0.28);
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    transform: translateX(-100%);
    visibility: hidden;
    transition: transform 0.3s cubic-bezier(0.32, 0.72, 0, 1), visibility 0s linear 0.3s;
  }

  /* 桌面宽度下 JS 已把抽屉搬出头部，这里必须重新收起，否则会平铺在页面顶部 */
  body:not(.np-drawer-on) .np-nav {
    height: 100%;
  }

  .np-nav.is-open {
    transform: translateX(0);
    visibility: visible;
    transition: transform 0.3s cubic-bezier(0.32, 0.72, 0, 1);
  }

  .np-drawer-mask {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 95;
    background: rgba(9, 14, 22, 0.48);
    opacity: 0;
    transition: opacity 0.24s ease;
  }

  .np-drawer-mask.is-on {
    opacity: 1;
  }

  /* display:block 会盖掉 [hidden] 的默认 display:none，必须显式声明 */
  .np-drawer-mask[hidden] {
    display: none;
  }

  /* --- 抽屉内容 --- */
  .np-drawer__top {
    display: flex;
    flex: none;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: calc(14px + env(safe-area-inset-top, 0px)) 16px 14px 18px;
    border-bottom: 1px solid var(--np-line);
  }

  /* 右上角：明暗 + 关闭 两个圆形小按钮 */
  .np-drawer__top-btns {
    display: flex;
    align-items: center;
    gap: 8px;
    /* 1.8.41：品牌区被隐藏时顶栏只剩这一组按钮，靠右站位不留空。 */
    margin-left: auto;
  }

  .np-drawer__logo {
    max-height: 30px;
    width: auto;
    object-fit: contain;
  }

  .np-drawer__name {
    font-size: 17px;
    font-weight: 800;
    color: var(--np-text);
  }

  .np-drawer__iconbtn {
    flex: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 50%;
    background: var(--np-bg-soft);
    color: var(--np-text-2);
    cursor: pointer;
    transition: var(--np-transition);
  }

  .np-drawer__iconbtn:hover {
    color: var(--np-primary);
    background: var(--np-primary-soft);
  }

  /* 明暗按钮：浅色显月亮、深色显太阳 */
  .np-drawer__dark .np-drawer__icon-sun {
    display: none;
  }

  body.np-dark .np-drawer__dark .np-drawer__icon-moon {
    display: none;
  }

  body.np-dark .np-drawer__dark .np-drawer__icon-sun {
    display: block;
  }

  body.np-dark .np-drawer__dark {
    color: #f5d76e;
  }

  /* 桌面 .np-nav 的 align-items:center 在抽屉里会把子项压成内容宽度，
     全部拉满，宽度交给下面的 margin/padding 控制。 */
  .np-nav {
    align-items: stretch;
  }

  /* --- 主菜单：两列胶囊按钮（对齐子比抽屉） --- */
  .np-nav ul {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    align-self: stretch;
    padding: 14px 16px 4px;
  }

  .np-nav li {
    width: auto;
    min-width: 0;
  }

  .np-nav li > a {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 6px 10px;
    border: 1px solid var(--np-line);
    border-radius: 10px;
    background: var(--np-bg-soft);
    font-size: 14px;
    font-weight: 500;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .np-nav .current-menu-item > a,
  .np-nav .current-menu-ancestor > a {
    border-color: var(--np-primary);
    background: var(--np-primary-soft);
    color: var(--np-primary);
  }

  /* 二级菜单跟一级一样平铺进网格：字号小一号、去底色，层级靠缩进文字表达 */
  .np-nav ul ul {
    display: contents;
  }

  .np-nav ul ul li > a {
    min-height: 38px;
    border-style: dashed;
    background: transparent;
    font-size: 13px;
    color: var(--np-text-2);
  }

  /* --- 语言：三个胶囊，当前项高亮 --- */
  .np-drawer__langs {
    flex: none;
    display: flex;
    gap: 8px;
    padding: 12px 16px 2px;
  }

  .np-drawer__chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    flex: 1;
    min-width: 0;
    height: 34px;
    padding: 0 8px;
    border: 1px solid var(--np-line);
    border-radius: 999px;
    background: transparent;
    color: var(--np-text-2);
    font-size: 12.5px;
    font-weight: 600;
    cursor: pointer;
  }

  .np-drawer__chip em {
    font-style: normal;
    font-weight: 500;
    font-size: 11.5px;
    color: var(--np-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .np-drawer__chip.is-active {
    border-color: var(--np-primary);
    background: var(--np-primary-soft);
    color: var(--np-primary);
  }

  .np-drawer__chip.is-active em {
    color: var(--np-primary);
  }

  /* --- 会员横幅：深色通栏，金色文字 --- */
  .np-drawer__vipbar {
    display: flex;
    flex: none;
    align-items: center;
    justify-content: center;
    gap: 7px;
    margin: 14px 16px 0;
    padding: 12px 14px;
    border-radius: 10px;
    background: linear-gradient(135deg, #23262e 0%, #33302a 100%);
    color: #f5d493;
    font-size: 14px;
  }

  .np-drawer__vipbar > svg {
    flex: none;
  }

  .np-drawer__vipbar strong {
    color: #f7ddaa;
    font-weight: 700;
  }

  .np-drawer__vipbar-sub {
    font-size: 12px;
    color: rgba(245, 212, 147, 0.72);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .np-drawer__vipbar.is-vip {
    background: linear-gradient(135deg, #1f2b25 0%, #2e3b2c 100%);
  }

  /* 这几个块本身是 <a>，全局 .np-nav a{display:block}（0,1,1）会盖掉下面
     单类选择器（0,1,0）的 flex 布局，导致会员横幅不居中、圆钮错位。
     统一提权到 0,2,1 把 display 抢回来，位置放在各自定义之后也不受影响。 */
  .np-nav a.np-drawer__vipbar {
    display: flex;
    /* 同样要提权：.np-nav a{color:var(--np-text-2)} 会把整条横幅（含图标）
       压成灰色，放在深色渐变背景上就是「不亮」。 */
    color: #f5d493;
  }

  .np-nav a.np-drawer__chip { display: inline-flex; }
  .np-nav a.np-drawer__circle { display: flex; }

  /* 皇冠做成实心 + 微光，描边太细在深色背景上几乎是隐形的 */
  .np-nav a.np-drawer__vipbar > svg {
    flex: none;
    fill: currentColor;
    filter: drop-shadow(0 0 3px rgba(245, 212, 147, 0.5));
  }

  /* --- 账号区 --- */
  .np-drawer__account {
    flex: none;
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 16px 16px calc(18px + env(safe-area-inset-bottom, 0px));
  }

  /* 未登录：三个彩色圆钮（登录 / 注册 / 找回密码），对齐子比 */
  .np-drawer__auth {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    padding: 0 6px;
  }

  .np-drawer__circle {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    min-width: 0;
  }

  .np-drawer__circle-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: var(--np-bg-soft);
    border: 1px solid var(--np-line);
    transition: var(--np-transition);
  }

  .np-drawer__circle-text {
    font-size: 12.5px;
    color: var(--np-text-2);
    white-space: nowrap;
  }

  .np-drawer__circle:hover .np-drawer__circle-icon {
    transform: translateY(-2px);
    box-shadow: 0 6px 14px rgba(9, 14, 22, 0.12);
  }

  .np-drawer__circle--login .np-drawer__circle-icon {
    color: var(--np-primary);
    background: var(--np-primary-soft);
    border-color: transparent;
  }

  .np-drawer__circle--login .np-drawer__circle-text {
    color: var(--np-primary);
  }

  .np-drawer__circle--reg .np-drawer__circle-icon {
    color: #2f9e5f;
    background: rgba(47, 158, 95, 0.12);
    border-color: transparent;
  }

  .np-drawer__circle--reg .np-drawer__circle-text {
    color: #2f9e5f;
  }

  .np-drawer__circle--lost .np-drawer__circle-icon {
    color: #d95f8f;
    background: rgba(217, 95, 143, 0.12);
    border-color: transparent;
  }

  .np-drawer__circle--lost .np-drawer__circle-text {
    color: #d95f8f;
  }

  /* 已登录：头像 + 用户名 + 用户中心 */
  .np-drawer__user {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
    color: var(--np-text-2);
  }

  .np-drawer__user-info {
    min-width: 0;
    display: flex;
    flex-direction: column;
    line-height: 1.4;
  }

  .np-drawer__user strong {
    font-size: 15px;
    color: var(--np-text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .np-drawer__user a,
  .np-drawer__user-link {
    font-size: 12.5px;
    color: var(--np-primary);
  }

  .np-drawer__user-sub {
    font-size: 12.5px;
    color: var(--np-muted);
  }

  /* 已登录且能写文章的人，抽屉里给一枚进后台的短链接 */
  .np-drawer__admin {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    padding: 7px 14px;
    border-radius: 999px;
    background: var(--np-bg-soft);
    font-size: 12.5px;
    color: var(--np-text);
    text-decoration: none;
  }

  .np-drawer__admin svg {
    width: 14px;
    height: 14px;
    flex: none;
  }

  .np-drawer__admin:hover {
    color: var(--np-primary);
  }

  .np-drawer__avatar {
    flex: none;
    width: 44px;
    height: 44px;
    border-radius: 50%;
  }

  /* --- 汉堡图标：三条杠，展开时变 X --- */
  .np-menu-toggle__bars {
    position: relative;
    display: block;
    width: 18px;
    height: 12px;
  }

  .np-menu-toggle__bars i {
    position: absolute;
    left: 0;
    width: 100%;
    height: 2px;
    border-radius: 2px;
    background: currentColor;
    transition: transform 0.28s ease, opacity 0.18s ease, top 0.28s ease;
  }

  .np-menu-toggle__bars i:nth-child(1) { top: 0; }
  .np-menu-toggle__bars i:nth-child(2) { top: 5px; }
  .np-menu-toggle__bars i:nth-child(3) { top: 10px; }

  .np-menu-toggle[aria-expanded='true'] .np-menu-toggle__bars i:nth-child(1) {
    top: 5px;
    transform: rotate(45deg);
  }

  .np-menu-toggle[aria-expanded='true'] .np-menu-toggle__bars i:nth-child(2) {
    opacity: 0;
  }

  .np-menu-toggle[aria-expanded='true'] .np-menu-toggle__bars i:nth-child(3) {
    top: 5px;
    transform: rotate(-45deg);
  }
}

@media (max-width: 640px) {
  body {
    font-size: 14.5px;
  }

  /* 侧栏组件在手机上是全宽单列，行高略微放开，别贴成一条 */
  .np-user__link {
    padding: 10px 12px;
  }

  .np-profile__cover {
    height: 150px;
  }

  .np-cal {
    padding: 14px;
  }

  .np-cal__day {
    font-size: 12.5px;
  }

  /* 页脚：单列后每块之间的垂直空隙最容易失控，这里逐项收紧 */
  .np-footer {
    margin-top: 40px;
    padding-top: 30px;
  }

  .np-footer__main {
    grid-template-columns: minmax(0, 1fr);
    gap: 26px;
    padding-bottom: 24px;
  }

  .np-footer__desc {
    margin-top: 10px;
    font-size: 13.5px;
    line-height: 1.7;
  }

  .np-footer__social {
    margin-top: 14px;
  }

  .np-footer__stats {
    gap: 0 10px;
    margin-top: 14px;
  }

  .np-footer__stats li {
    font-size: 12px;
  }

  .np-footer__stats strong {
    font-size: 16px;
  }

  .np-footer__title {
    margin-bottom: 8px;
    font-size: 12px;
  }

  .np-footer__list {
    /* 窄屏两列排，比一路竖着堆短得多 */
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 16px;
  }

  .np-footer__list a {
    padding: 6px 0;
    font-size: 13.5px;
  }

  .np-footer__widgets {
    grid-template-columns: minmax(0, 1fr);
    gap: 22px;
    padding-bottom: 24px;
  }

  /* 窄屏备案与版权都居中：上面胶囊居中、下面一行左对齐，看着像没对齐过的两块。 */
  .np-footer__bottom {
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 8px;
    padding: 14px 0 18px;
    font-size: 12.5px;
  }

  .np-footer__nav {
    justify-content: center;
    gap: 6px 16px;
  }

  /* 窄屏备案信息竖排：横排换行后每行长短不齐，看着比一列更乱 */
  .np-footer__icp .np-icp--inline .np-icp__list {
    flex-direction: column;
    align-items: center;
    gap: 4px;
  }

  /* 手机备案：原来按文字长短自动换行，四条宽度 242/276/258/215 参差不齐，
     换行位置也各说各话。改成一列等宽、内容居中——读起来是一份清单，
     点按区域同时从「一小块」变成「整行」。 */
  .np-footer__icp .np-icp--chip .np-icp__list {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
  }

  .np-footer__icp .np-icp--chip .np-icp__item {
    width: 100%;
    max-width: 320px;
  }

  .np-footer__icp .np-icp--chip .np-icp__chip {
    width: 100%;
    justify-content: center;
    padding: 8px 14px;
  }

  .np-footer__icp .np-icp--chip .np-icp__label {
    flex: none;
  }

  /* 手机上头部只留「菜单 + 站名 + 搜索」：
     语言、明暗、账号都进了抽屉，头部再堆三个按钮，站名会被挤成省略号。
     1.8.37：只限定 .np-header 内的按钮，左下角侧边栏里的同款入口不受影响。 */
  .np-header .np-lang,
  .np-header .np-dark-toggle,
  .np-header .np-user-toggle {
    display: none;
  }

  /* 手机图文列表
   *
   * 原来缩略图 130×81、摘要两行、meta 四项挤成一排换行，一条 188px 高，
   * 一屏只能看到两条半。改成：
   *   - 缩略图 116×87（4:3 略偏方），信息密度更接近常见资讯 App；
   *   - 摘要收一行，meta 只留作者 + 日期 + 阅读数，其余交给详情页；
   *   - 条目本身卡片化（白底 + 圆角），条目之间的分隔线换成留白。
   */
  .np-post-list {
    gap: 10px;
  }

  .np-post-item {
    grid-template-columns: 116px minmax(0, 1fr);
    gap: 12px;
    padding: 12px;
    border: 1px solid var(--np-line);
    border-bottom: 1px solid var(--np-line);
    border-radius: 12px;
    background: var(--np-bg);
  }

  .np-post-item:last-child {
    padding-bottom: 12px;
    border-bottom: 1px solid var(--np-line);
  }

  .np-post-item__thumb {
    align-self: start;
    aspect-ratio: 4 / 3;
    border-radius: 9px;
  }

  .np-post-item__thumb--empty {
    min-height: 0;
    font-size: 11px;
  }

  .np-post-item__title {
    margin: 0 0 6px;
    font-size: 15px;
    line-height: 1.42;
    font-weight: 650;
  }

  .np-post-item__excerpt {
    margin: 0 0 8px;
    font-size: 12.5px;
    line-height: 1.6;
    -webkit-line-clamp: 1;
  }

  /* meta 在窄条里只留「作者 · 日期 · 阅读」，且必须死守一行——
     作者名一长就被挤到第二行，右侧就空出一块，条目高度还会跟着字数跳。 */
  .np-post-item .np-post-meta {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    gap: 0 6px;
    height: 18px;
    overflow: hidden;
    font-size: 11.5px;
    color: var(--np-muted);
    white-space: nowrap;
  }

  /* 阅读时间、评论数在小屏上没有决策价值，隐藏（nth-last-child 从后往前数两项） */
  .np-post-item .np-post-meta > span:nth-last-child(-n + 2) {
    display: none;
  }

  /* 侧栏宽度只有 190px 上下，塞不下头像 + 作者 + 日期 + 阅读数。
     小屏干脆不显示作者（列表页本来也不靠作者做判断），只留「日期 · 阅读」。 */
  .np-post-item .np-post-meta__author {
    display: none;
  }

  .np-post-item .np-post-meta > time::before {
    content: none;
  }

  .np-post-item .np-post-meta > span + span::before,
  .np-post-item .np-post-meta > span + time::before,
  .np-post-item .np-post-meta > time + span::before {
    content: '·';
    margin-right: 6px;
    color: var(--np-line);
  }

  .np-post-item .np-post-meta__avatar {
    width: 16px;
    height: 16px;
  }

  /* 图片加载失败的 alt 文字会撑出灰底长条，这里裁掉 */
  .np-post-item__thumb img {
    display: block;
  }

  .np-post-grid,
  .np-video-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  /* 视频专区在单列下缩略图占满整宽，按钮与角标同步收一号，避免过于抢眼。 */
  .np-video-card__thumb {
    min-height: 160px;
  }

  .np-video-card__play span {
    width: 40px;
    height: 40px;
    font-size: 13px;
  }

  .np-video-card__meta {
    right: 10px;
    bottom: 10px;
    font-size: 11px;
  }

  .np-video-card > h4 {
    margin-top: 9px !important;
    font-size: 14.5px !important;
    line-height: 1.45;
  }

  .np-single__title {
    font-size: 23px;
  }

  .np-post-nav {
    grid-template-columns: minmax(0, 1fr);
  }

  .np-post-nav__item--next {
    text-align: left;
  }

  .np-slider__slide {
    min-height: 240px;
  }

  .np-slider__caption {
    padding: 18px 20px;
  }

  .np-slider__caption h2 {
    font-size: 19px;
  }

  /* 热门频道：横向滑动的频道条（≤640px）
   * 一排 4 个的网格在窄屏里每个格子只有 80px 上下，长分类名要么折行要么
   * 挤成竖条。改成单行横向滑动：分类多时左右滑，少时自然收拢，观感同
   * 常见资讯 App 的频道栏。滚动条隐藏，右缘一道淡出提示还能滑。 */
  .np-cats {
    display: flex;
    flex-wrap: nowrap;
    gap: 8px;
    overflow-x: auto;
    padding: 2px 2px 6px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    scroll-snap-type: x proximity;
    -webkit-mask-image: linear-gradient(to right, #000 0, #000 calc(100% - 22px), transparent 100%);
    mask-image: linear-gradient(to right, #000 0, #000 calc(100% - 22px), transparent 100%);
  }

  .np-cats::-webkit-scrollbar {
    display: none;
  }

  .np-cat {
    flex: 0 0 auto;
    gap: 7px;
    padding: 9px 15px;
    border-radius: 999px;
    background: var(--np-bg);
    box-shadow: inset 0 0 0 1px var(--np-line), 0 1px 3px rgba(0, 0, 0, 0.05);
    font-size: 13px;
    font-weight: 600;
    white-space: nowrap;
    scroll-snap-align: start;
    -webkit-tap-highlight-color: transparent;
  }

  .np-cat:active {
    transform: scale(0.96);
  }

  .np-cat__dot {
    width: 8px;
    height: 8px;
    /* 圆点外围的淡色光晕取各自频道的颜色（modules.php 内联到 --np-cat-color） */
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--np-cat-color, #999) 16%, transparent);
  }

  .np-cat__count {
    padding: 1px 8px;
    border-radius: 999px;
    background: rgba(125, 125, 125, 0.12);
    font-size: 11px;
    font-weight: 500;
    line-height: 1.5;
  }
}

/* 超窄屏（≤380px）：站名 + 菜单 + 三个图标按钮容易顶出屏幕，
   压缩间距并允许站名省略，避免整页横向溢出。 */
@media (max-width: 380px) {
  .np-header__inner {
    gap: 10px;
  }

  .np-brand {
    min-width: 0;
    overflow: hidden;
    font-size: 16px;
  }

  .np-header__actions {
    gap: 5px;
    flex: none;
  }

  .np-search-toggle,
  .np-dark-toggle,
  .np-translate-toggle,
  .np-user-toggle {
    width: 31px;
    height: 31px;
  }

}

@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

/* ==========================================================================
   11. WordPress 必需类
   ========================================================================== */
.alignleft { float: left; margin: 6px 18px 12px 0; }
.alignright { float: right; margin: 6px 0 12px 18px; }
.aligncenter { display: block; margin: 12px auto; }
.wp-caption { max-width: 100%; }
.gallery-caption { display: block; }
.bypostauthor { display: block; }
.sticky { position: relative; }
.np-sticky-flag {
  color: var(--np-accent);
  font-weight: 600;
}

/* ==========================================================================
   12. VIP 会员页
   ========================================================================== */
.np-vip-hero {
  position: relative;
  margin: 28px 0 24px;
  padding: 56px 32px 48px;
  border-radius: 18px;
  overflow: hidden;
  background: linear-gradient(135deg, #14181f 0%, #1d2530 45%, #2a1f18 100%);
  color: #fff;
  text-align: center;
}

.np-vip-hero__glow {
  position: absolute;
  inset: -40% -10% auto -10%;
  height: 420px;
  background: radial-gradient(closest-side, rgba(214, 154, 20, 0.35), transparent 70%);
  pointer-events: none;
}

/* hero 外层裁剪光晕，避免横向溢出撑出滚动条。 */
.np-vip-hero {
  overflow: hidden;
}

.np-vip-hero__inner {
  position: relative;
  max-width: 720px;
  margin: 0 auto;
}

.np-vip-hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.18);
  font-size: 13px;
  letter-spacing: 0.02em;
  color: #f5d493;
}

.np-vip-hero__title {
  margin: 18px 0 12px;
  font-size: 34px;
  line-height: 1.28;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.np-vip-hero__desc {
  margin: 0;
  font-size: 15px;
  line-height: 1.8;
  color: rgba(255, 255, 255, 0.78);
}

.np-vip-hero__desc strong {
  color: #f5d493;
}

.np-vip-hero__notice {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 20px;
  padding: 9px 16px;
  border-radius: 999px;
  background: rgba(46, 160, 67, 0.18);
  border: 1px solid rgba(46, 160, 67, 0.4);
  font-size: 13.5px;
  color: #8ff0a4;
}

.np-vip-hero__notice--warn {
  background: rgba(214, 154, 20, 0.16);
  border-color: rgba(214, 154, 20, 0.42);
  color: #f3cf87;
}

.np-vip-hero.is-active .np-vip-hero__glow {
  background: radial-gradient(closest-side, rgba(46, 160, 67, 0.3), transparent 70%);
}

/* 权益 */
.np-vip-benefits {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 40px;
}

.np-vip-benefit {
  padding: 22px 20px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
  transition: border-color 0.18s ease, transform 0.18s ease;
}

.np-vip-benefit:hover {
  border-color: var(--np-primary);
  transform: translateY(-2px);
}

.np-vip-benefit__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 11px;
  background: var(--np-primary-soft);
  color: var(--np-primary);
}

.np-vip-benefit__title {
  margin: 14px 0 6px;
  font-size: 15.5px;
  font-weight: 600;
}

.np-vip-benefit__desc {
  margin: 0;
  font-size: 13px;
  line-height: 1.7;
  color: var(--np-muted);
}

/* 套餐 */
.np-vip-plans {
  margin-bottom: 40px;
  text-align: center;
}

.np-vip-plans__sub {
  margin: -6px 0 24px;
  font-size: 13.5px;
  color: var(--np-muted);
}

.np-vip-plan-grid {
  display: grid;
  /* 4 档套餐（月/季/年/永久）一行铺满，窄屏自动降列 */
  grid-template-columns: repeat(auto-fit, minmax(0, 1fr));
  gap: 16px;
  align-items: stretch;
}

.np-vip-plan-grid:has(.np-vip-plan:nth-child(4)) {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.np-vip-plan-grid:has(.np-vip-plan:nth-child(4)) .np-vip-plan {
  padding: 28px 18px 24px;
}

.np-vip-plan-grid:has(.np-vip-plan:nth-child(4)) .np-vip-plan__cur {
  font-size: 27px;
}

.np-vip-plan {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 30px 24px 26px;
  border: 1px solid var(--np-line);
  border-radius: 16px;
  background: var(--np-bg);
  text-align: left;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.np-vip-plan:hover {
  border-color: var(--np-primary);
  box-shadow: var(--np-shadow);
  transform: translateY(-3px);
}

.np-vip-plan.is-featured {
  border-color: #c99a35;
  box-shadow: 0 0 0 1px rgba(201, 154, 53, 0.35), 0 16px 40px -18px rgba(201, 154, 53, 0.5);
}

/* 永久卡：紫色描边区分「一次买断」 */
.np-vip-plan.is-lifetime {
  border-color: #7c5cff;
  background: linear-gradient(180deg, rgba(124, 92, 255, 0.05), transparent 60%);
}

.np-vip-plan.is-lifetime:hover {
  border-color: #6a48f5;
  box-shadow: 0 16px 40px -20px rgba(124, 92, 255, 0.55);
}

.np-vip-plan__tag--perm {
  background: #7c5cff;
  color: #fff;
}

/* 永久卡已拥有：整卡去饱和、按钮禁用，一眼看出「不用再买」 */
.np-vip-plan.is-disabled {
  opacity: 0.62;
}

.np-vip-plan.is-disabled .np-vip-plan__btn {
  background: var(--np-bg-soft);
  color: var(--np-muted);
  border: 1px solid var(--np-line);
  cursor: not-allowed;
}

.np-vip-plan .np-vip-plan__tag--owned {
  background: var(--np-text-2);
  color: #fff;
}

/* 可升级角标：会员视角下档位更高的卡 */
.np-vip-plan .np-vip-plan__tag--upgrade {
  background: var(--np-primary);
  color: #fff;
}

.np-vip-plan__tag {
  position: absolute;
  top: -12px;
  left: 24px;
  padding: 4px 12px;
  border-radius: 999px;
  background: linear-gradient(135deg, #d6a028, #b8821a);
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.np-vip-plan__name {
  margin: 0 0 14px;
  font-size: 17px;
  font-weight: 600;
}

.np-vip-plan__price {
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.np-vip-plan__cur {
  font-size: 34px;
  font-weight: 700;
  line-height: 1.1;
  color: var(--np-text);
  letter-spacing: -0.02em;
}

.np-vip-plan__days {
  font-size: 13px;
  color: var(--np-muted);
}

.np-vip-plan__origin {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
  font-size: 13px;
  color: var(--np-muted);
}

.np-vip-plan__save {
  padding: 1px 7px;
  border-radius: 4px;
  background: rgba(214, 54, 56, 0.1);
  color: var(--np-accent);
  font-size: 12px;
}

.np-vip-plan__perday {
  margin: 10px 0 20px;
  padding-bottom: 18px;
  border-bottom: 1px dashed var(--np-line);
  font-size: 12.5px;
  color: var(--np-muted);
}

.np-vip-plan__btn {
  margin-top: auto;
  width: 100%;
}

.np-vip-login-tip {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 32px;
  padding: 14px 18px;
  border: 1px dashed var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg-soft);
  font-size: 14px;
  color: var(--np-text-2);
}

.np-vip-login-tip svg {
  flex: 0 0 auto;
  color: var(--np-muted);
}

.np-vip-orders {
  margin-bottom: 40px;
}

.np-vip-faq {
  margin-bottom: 48px;
}

.np-faq__item {
  border-bottom: 1px solid var(--np-line);
}

.np-faq__item summary {
  padding: 16px 0;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  list-style: none;
  position: relative;
  padding-right: 28px;
}

.np-faq__item summary::-webkit-details-marker {
  display: none;
}

.np-faq__item summary::after {
  content: "+";
  position: absolute;
  right: 4px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 20px;
  color: var(--np-muted);
  font-weight: 400;
}

.np-faq__item[open] summary::after {
  content: "\2212";
}

.np-faq__item p {
  margin: 0 0 18px;
  font-size: 14px;
  line-height: 1.85;
  color: var(--np-text-2);
}

/* ==========================================================================
   13. 付费短代码：锁定态与下载
   ========================================================================== */
.np-locked {
  position: relative;
  margin: 28px 0;
}

.np-locked--pay {
  border-radius: var(--np-radius);
  overflow: hidden;
}

.np-locked__mask {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 22px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius) var(--np-radius) 0 0;
  background: var(--np-bg-soft);
  filter: blur(5px);
  opacity: 0.55;
  pointer-events: none;
  user-select: none;
  max-height: 150px;
  overflow: hidden;
}

.np-locked__mask span {
  height: 10px;
  border-radius: 5px;
  background: #d5dae1;
}

.np-locked__mask span:nth-child(1) { width: 92%; }
.np-locked__mask span:nth-child(2) { width: 74%; }
.np-locked__mask span:nth-child(3) { width: 88%; }
.np-locked__mask span:nth-child(4) { width: 62%; }
.np-locked__mask span:nth-child(5) { width: 80%; }
.np-locked__mask span:nth-child(6) { width: 45%; }

.np-locked__box {
  position: relative;
  margin-top: -78px;
  padding: 34px 26px 30px;
  border: 1px solid var(--np-line);
  border-top: 0;
  border-radius: 0 0 var(--np-radius) var(--np-radius);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, var(--np-bg) 42%);
  text-align: center;
}

.np-locked__badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
  margin-bottom: 14px;
  border-radius: 50%;
  background: var(--np-primary-soft);
  color: var(--np-primary);
}

.np-locked__title {
  margin: 0 0 8px;
  font-size: 18px;
  font-weight: 600;
}

.np-locked__desc {
  margin: 0 0 16px;
  font-size: 13.5px;
  line-height: 1.75;
  color: var(--np-muted);
}

.np-locked__price {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 10px;
  margin-bottom: 20px;
}

.np-locked__cur {
  font-size: 30px;
  font-weight: 700;
  color: var(--np-accent);
  letter-spacing: -0.02em;
}

.np-locked__unit {
  font-size: 12.5px;
  color: var(--np-muted);
}

.np-locked__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
}

.np-locked__tip {
  margin: 16px 0 0;
  font-size: 12.5px;
  color: var(--np-muted);
}

.np-locked__tip a {
  color: var(--np-primary);
}

.np-locked--open {
  margin: 28px 0;
}

.np-locked--vip {
  padding: 30px 24px;
  border: 1px dashed #d9c08a;
  border-radius: var(--np-radius);
  background: linear-gradient(180deg, #fdf9ee, #fffdf8);
  text-align: center;
}

.np-locked--vip .np-locked__badge {
  background: rgba(201, 154, 53, 0.14);
  color: #b8821a;
}

.np-locked--vip .np-locked__actions {
  margin-top: 18px;
}

/* 下载条 */
.np-download {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 20px 0;
  padding: 16px 18px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg-soft);
}

.np-download--paid {
  border-color: rgba(46, 160, 67, 0.35);
  background: rgba(46, 160, 67, 0.06);
}

.np-download__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: var(--np-bg);
  border: 1px solid var(--np-line);
  color: var(--np-primary);
}

.np-download__body {
  flex: 1 1 auto;
  min-width: 0;
}

.np-download__name {
  font-size: 14.5px;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.np-download__meta {
  margin-top: 3px;
  font-size: 12.5px;
  color: var(--np-muted);
}

.np-download__size {
  margin-left: 8px;
  padding: 1px 6px;
  border-radius: 3px;
  background: var(--np-bg);
  border: 1px solid var(--np-line);
  font-size: 11.5px;
}

.np-download__btn {
  flex: 0 0 auto;
}

/* ==========================================================================
   14. 支付收银台
   ========================================================================== */
.np-pay {
  max-width: 1000px;
  margin: 32px auto 56px;
}

.np-pay__head {
  margin-bottom: 26px;
  text-align: center;
}

.np-pay__title {
  margin: 0 0 8px;
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.np-pay__sub {
  margin: 0;
  font-size: 14px;
  color: var(--np-muted);
}

.np-pay__grid {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 24px;
  align-items: start;
}

.np-pay__card {
  padding: 22px 24px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
}

.np-pay__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 11px 0;
  border-bottom: 1px dashed var(--np-line);
  font-size: 14px;
}

.np-pay__row:last-child {
  border-bottom: 0;
}

.np-pay__label {
  flex: 0 0 auto;
  color: var(--np-muted);
}

.np-pay__value {
  text-align: right;
  word-break: break-all;
}

.np-pay__row--amount {
  border-bottom: 0;
  padding-top: 14px;
}

.np-pay__amount {
  font-size: 28px;
  font-weight: 700;
  color: var(--np-accent);
  letter-spacing: -0.02em;
}

.np-pay__methods {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin: 20px 0;
}

.np-pay__method {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 13px 14px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg);
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease;
}

.np-pay__method:hover {
  border-color: var(--np-primary);
}

.np-pay__method.is-active {
  border-color: var(--np-primary);
  background: var(--np-primary-soft);
  box-shadow: 0 0 0 1px var(--np-primary) inset;
}

.np-pay__method input {
  display: none;
}

.np-pay__method-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--np-bg-soft);
  color: var(--np-text-2);
}

.np-pay__method-logo--alipay_f2f,
.np-pay__method-logo--alipay_personal {
  background: rgba(22, 119, 255, 0.1);
  color: #1677ff;
}

.np-pay__method-logo--wechat,
.np-pay__method-logo--wechat_personal {
  background: rgba(7, 193, 96, 0.12);
  color: #07c160;
}

.np-pay__method-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.np-pay__method-text strong {
  font-size: 13.5px;
  font-weight: 600;
}

.np-pay__method-text small {
  margin-top: 2px;
  font-size: 11.5px;
  color: var(--np-muted);
}

.np-pay__stage {
  min-height: 60px;
}

.np-pay__loading {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 18px;
  border: 1px dashed var(--np-line);
  border-radius: var(--np-radius-sm);
  font-size: 13.5px;
  color: var(--np-muted);
}

.np-pay__warn {
  padding: 14px 16px;
  border: 1px solid rgba(214, 54, 56, 0.3);
  border-radius: var(--np-radius-sm);
  background: rgba(214, 54, 56, 0.06);
  font-size: 13.5px;
  color: var(--np-accent);
}

.np-pay__done {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin: 18px 0;
  padding: 16px;
  border: 1px solid rgba(46, 160, 67, 0.34);
  border-radius: var(--np-radius-sm);
  background: rgba(46, 160, 67, 0.07);
  color: #1a7f37;
}

.np-pay__done p {
  margin: 4px 0 0;
  font-size: 13px;
  color: var(--np-text-2);
}

.np-pay__right {
  position: sticky;
  top: 80px;
}

.np-pay__qrcode {
  padding: 20px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
  text-align: center;
}

.np-pay__qr-img {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 220px;
  font-size: 13px;
  color: var(--np-muted);
}

/* 当面付的二维码现在是前端本地画的 SVG（不再走 <img>），
 * 两种载体必须同规格：白底卡片、随容器缩放。
 * 写死 220px 在窄栏里会溢出，在宽栏里又显得小——
 * 用 min() 让它撑到 260px 封顶、小屏自动收窄。 */
.np-pay__qr-img img,
.np-pay__qr-img svg {
  display: block;
  width: min(260px, 100%);
  height: auto;
  aspect-ratio: 1 / 1;
  padding: 8px;
  border: 1px solid var(--np-line);
  border-radius: 10px;
  background: #fff;
  box-sizing: border-box;
  /* SVG 是矢量，不需要 pixelated；那会让缩放后的模块边缘发虚/锯齿 */
  shape-rendering: crispEdges;
}

/* 手机上把二维码再放大一号：扫码时手机离屏幕近，260px 偏小 */
@media (max-width: 600px) {
  .np-pay__qr-img img,
  .np-pay__qr-img svg {
    width: min(300px, 100%);
  }

  .np-pay__qrcode {
    padding: 16px 12px;
  }
}

.np-pay__qr-tip {
  margin: 14px 0 0;
  font-size: 12.5px;
  line-height: 1.7;
  color: var(--np-muted);
}

.np-pay__status {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 12px;
  padding: 11px;
  border-radius: var(--np-radius-sm);
  background: var(--np-bg-soft);
  font-size: 13px;
  color: var(--np-text-2);
}

.np-pay__status.is-ok {
  background: rgba(46, 160, 67, 0.1);
  color: #1a7f37;
  font-weight: 600;
}

.np-pay__status.is-fail {
  background: rgba(214, 54, 56, 0.08);
  color: var(--np-accent);
}

.np-pay__help {
  margin: 18px 0;
  padding: 16px 18px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg-soft);
}

.np-pay__help h3 {
  margin: 0 0 10px;
  font-size: 13.5px;
  font-weight: 600;
}

.np-pay__help ul {
  margin: 0;
  padding-left: 16px;
  font-size: 12.5px;
  line-height: 1.85;
  color: var(--np-muted);
}

.np-pay-empty {
  max-width: 440px;
  margin: 80px auto;
  text-align: center;
  color: var(--np-text-2);
}

.np-pay-empty svg {
  color: var(--np-muted);
}

.np-pay-empty h1 {
  margin: 16px 0 8px;
  font-size: 22px;
}

.np-pay-empty p {
  margin: 0 0 22px;
  font-size: 14px;
  color: var(--np-muted);
}

/* 通用小件 */
.np-btn--block {
  display: block;
  width: 100%;
  text-align: center;
}

.np-btn--lg {
  padding: 12px 26px;
  font-size: 15px;
}

.np-spinner {
  display: inline-block;
  width: 16px;
  height: 16px;
  border: 2px solid var(--np-line);
  border-top-color: var(--np-primary);
  border-radius: 50%;
  animation: np-spin 0.7s linear infinite;
}

.np-spinner--sm {
  width: 13px;
  height: 13px;
  border-width: 1.6px;
}

@keyframes np-spin {
  to { transform: rotate(360deg); }
}

.np-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
}

.np-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13.5px;
}

.np-table th,
.np-table td {
  padding: 11px 14px;
  text-align: left;
  border-bottom: 1px solid var(--np-line);
  white-space: nowrap;
}

.np-table th {
  background: var(--np-bg-soft);
  font-weight: 600;
  font-size: 12.5px;
  color: var(--np-muted);
}

.np-table tbody tr:last-child td {
  border-bottom: 0;
}

.np-table code {
  font-size: 12px;
  padding: 1px 5px;
  border-radius: 3px;
  background: var(--np-bg-soft);
}

.np-status {
  display: inline-block;
  padding: 2px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 500;
}

.np-status--paid {
  background: rgba(46, 160, 67, 0.12);
  color: #1a7f37;
}

.np-status--pending {
  background: rgba(214, 154, 20, 0.14);
  color: #8a6100;
}

.np-status--closed,
.np-status--refunded {
  background: var(--np-bg-soft);
  color: var(--np-muted);
}

/* 后台订单统计 */
.np-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 14px;
  margin: 18px 0 22px;
}

.np-stat {
  padding: 16px 18px;
  border: 1px solid #dcdcde;
  border-radius: 8px;
  background: #fff;
}

.np-stat.is-warn {
  border-color: #dba617;
  background: #fcf9e8;
}

.np-stat__label {
  display: block;
  font-size: 12px;
  color: #646970;
}

.np-stat__value {
  display: block;
  margin: 6px 0 2px;
  font-size: 22px;
  line-height: 1.2;
  color: #1d2327;
}

.np-stat__sub {
  font-size: 11.5px;
  color: #8c8f94;
}

.np-orders-table {
  margin-top: 12px;
}

.np-orders-table .np-muted {
  color: #8c8f94;
  font-size: 12px;
}

/* 订单页工具条：搜索 + 一键清除 */
.np-orders-bar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin: 12px 0 4px;
}

.np-orders-bar .np-orders-search {
  margin: 0;
}

.np-orders-bar .search-box {
  margin: 0;
}

.np-orders-wipe {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  padding-top: 2px;
}

.np-orders-wipe .button-link-delete {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  text-decoration: none;
}

.np-orders-wipe .dashicons {
  font-size: 16px;
  width: 16px;
  height: 16px;
  line-height: 1;
}

.np-orders-wipe .description {
  font-size: 12px;
  color: #8c8f94;
}

@media (max-width: 782px) {
  .np-orders-wipe .description {
    display: none;
  }
}

.newspress-sc-help code {
  font-size: 12px;
}

/* ==========================================================================
   15. VIP / 支付响应式
   ========================================================================== */
@media (max-width: 1024px) {
  .np-vip-benefits {
    grid-template-columns: repeat(2, 1fr);
  }

  .np-pay__grid {
    grid-template-columns: 1fr;
  }

  .np-pay__right {
    position: static;
  }
}

@media (max-width: 782px) {
  .np-vip-hero {
    margin: 16px 0 18px;
    padding: 40px 20px 34px;
    border-radius: 14px;
  }

  .np-vip-hero__title {
    font-size: 25px;
  }

  .np-vip-hero__desc {
    font-size: 14px;
  }

  .np-vip-benefits {
    grid-template-columns: 1fr;
    gap: 12px;
    margin-bottom: 28px;
  }

  .np-vip-benefit {
    display: flex;
    align-items: flex-start;
    gap: 13px;
    padding: 16px;
  }

  /* 移动端图标与文字并排，文字区需可收缩，避免标题被 icon 挤成两行 */
  .np-vip-benefit > div {
    flex: 1 1 auto;
    min-width: 0;
  }

  .np-vip-benefit__icon {
    flex: 0 0 auto;
    width: 36px;
    height: 36px;
    border-radius: 9px;
  }

  .np-vip-benefit__title {
    margin: 2px 0 5px;
    white-space: nowrap;
  }

  /* 四档套餐在窄屏必须回到单列，这里要压过 :has() 的 4 列规则。 */
  .np-vip-plan-grid,
  .np-vip-plan-grid:has(.np-vip-plan:nth-child(4)) {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .np-vip-plan-grid:has(.np-vip-plan:nth-child(4)) .np-vip-plan {
    padding: 24px 20px 22px;
  }

  .np-vip-plan-grid:has(.np-vip-plan:nth-child(4)) .np-vip-plan__cur {
    font-size: 30px;
  }

  .np-vip-plan {
    padding: 24px 20px 22px;
  }

  .np-vip-plan.is-featured {
    order: -1;
  }

  .np-vip-plan__cur {
    font-size: 30px;
  }

  .np-locked__box {
    padding: 28px 18px 24px;
  }

  .np-locked__actions {
    flex-direction: column;
  }

  .np-locked__actions .np-btn {
    width: 100%;
  }

  .np-download {
    flex-wrap: wrap;
    gap: 10px 12px;
    padding: 14px;
  }

  .np-download__body {
    flex: 1 1 calc(100% - 60px);
  }

  .np-download__btn {
    width: 100%;
    margin-top: 2px;
  }

  .np-pay {
    margin: 18px auto 40px;
  }

  .np-pay__title {
    font-size: 21px;
  }

  .np-pay__card {
    padding: 16px 16px;
  }

  .np-pay__amount {
    font-size: 24px;
  }

  .np-pay__methods {
    grid-template-columns: 1fr;
  }

  .np-pay__method {
    padding: 11px 12px;
  }

  .np-pay__qr-img img,
  .np-pay__qr-img svg {
    width: min(210px, 100%);
  }

  .np-pay__help {
    padding: 14px;
  }
}

/* 锁定卡片 / 下载条内的标题不要继承正文 h2/h3 的左侧装饰线 */
.np-entry .np-locked__title,
.np-entry .np-download__name,
.np-entry .np-pay__help h3,
.np-entry .np-vip-benefit__title {
  margin: 0 0 8px;
  padding-left: 0;
  border-left: 0;
}

.np-entry .np-download__name {
  margin: 0;
}

.np-entry .np-pay__help h3 {
  margin: 0 0 10px;
}

.np-entry .np-vip-benefit__title {
  margin: 14px 0 6px;
}

/* ==========================================================================
   16. 用户中心：会员卡 / 订单表 / 紧凑套餐
   ========================================================================== */
.np-account__vipcard {
  background: linear-gradient(160deg, rgba(124, 92, 255, 0.08), transparent 65%);
  border-color: rgba(124, 92, 255, 0.28);
}

.np-account__vipstate {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 0 0 6px;
  padding: 5px 11px;
  border-radius: 999px;
  background: rgba(201, 154, 53, 0.14);
  color: #9a7320;
  font-size: 13px;
  font-weight: 600;
}

.np-account__vipstate--perm {
  background: rgba(124, 92, 255, 0.14);
  color: #5b3fd6;
}

.np-account__vipstate--none {
  background: var(--np-bg-soft);
  color: var(--np-muted);
}

.np-account__vipbtn {
  display: block;
  width: 100%;
  margin-top: 10px;
  text-align: center;
}

/* 订单计数角标 */
.np-account__count {
  display: inline-block;
  min-width: 20px;
  margin-left: 6px;
  padding: 1px 7px;
  border-radius: 999px;
  background: var(--np-primary-soft);
  color: var(--np-primary);
  font-size: 12px;
  font-weight: 600;
  vertical-align: middle;
  text-align: center;
}

.np-account__link {
  color: var(--np-primary);
  font-weight: 500;
}

.np-account__link:hover {
  text-decoration: underline;
}

.np-account__muted {
  color: var(--np-muted);
}

.np-account__hint--warn {
  color: #b45309;
}

/* 用户中心里的紧凑套餐卡 */
.np-vip-plan-grid--compact {
  gap: 12px;
  margin-top: 14px;
}

.np-vip-plan-grid--compact .np-vip-plan {
  padding: 20px 14px 16px;
  border-radius: 13px;
}

.np-vip-plan-grid--compact .np-vip-plan__name {
  font-size: 15px;
}

.np-vip-plan-grid--compact .np-vip-plan__cur {
  font-size: 24px;
}

.np-vip-plan-grid--compact .np-vip-plan__days {
  font-size: 12px;
}

.np-vip-plan-grid--compact .np-vip-plan__origin,
.np-vip-plan-grid--compact .np-vip-plan__perday {
  font-size: 12px;
}

.np-vip-plan-grid--compact .np-vip-plan__btn {
  padding: 9px 10px;
  font-size: 13px;
}

.np-vip-plan.is-owned {
  opacity: 0.75;
}

@media (max-width: 782px) {
  .np-vip-plan-grid--compact {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .np-vip-plan-grid--compact .np-vip-plan__cur {
    font-size: 21px;
  }

  /* 订单表在手机上转成竖排卡片 */
  .np-table--orders thead {
    display: none;
  }

  .np-table--orders,
  .np-table--orders tbody,
  .np-table--orders tr,
  .np-table--orders td {
    display: block;
    width: 100%;
  }

  .np-table--orders tr {
    margin-bottom: 12px;
    border: 1px solid var(--np-line);
    border-radius: 10px;
    overflow: hidden;
  }

  .np-table--orders td {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 9px 13px;
    border: 0;
    border-bottom: 1px solid var(--np-line);
    text-align: right;
  }

  .np-table--orders td:last-child {
    border-bottom: 0;
  }

  .np-table--orders td::before {
    content: attr(data-label);
    flex: none;
    color: var(--np-muted);
    font-size: 12.5px;
    text-align: left;
  }
}


/* ==========================================================================
   手机端网页翻译：入口收进抽屉顶栏，语言菜单就地展开
   ========================================================================== */
@media (max-width: 960px) {
  /* 头部不再重复放翻译按钮，抽屉顶栏已有同款且紧挨明暗切换。
     1.8.50：翻译只留电脑版顶部这一枚；手机端连同快捷工具面板里的入口一起移除，
     避免和抽屉顶栏重复。 */
  .np-header .np-header__actions .np-translate-wrap {
    display: none;
  }

  .np-drawer__translate[aria-expanded="true"] {
    color: var(--np-primary);
    background: var(--np-primary-soft);
  }

  /* 抽屉 overflow-y:auto 会裁切绝对定位浮层，所以改成顶栏下方就地展开，
     两列排布，8 个语种只占 4 行。 */
  .np-nav .np-translate-menu--inline {
    position: static;
    display: none;
    flex: none;
    align-self: stretch;
    width: auto;
    max-height: none;
    margin: 0;
    padding: 10px 16px 12px;
    border: 0;
    border-bottom: 1px solid var(--np-line);
    border-radius: 0;
    background: var(--np-bg-soft);
    box-shadow: none;
    z-index: auto;
  }

  .np-nav .np-translate-menu--inline.is-open {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 7px;
  }

  /* 全局 .np-nav a{display:block} 特异性 0,1,1，这里提权把 flex 布局抢回来 */
  .np-nav .np-translate-menu__item {
    display: flex;
    min-width: 0;
    padding: 9px 10px;
    border: 1px solid var(--np-line);
    border-radius: 9px;
    background: var(--np-bg);
    font-size: 12.5px;
  }

  .np-nav .np-translate-menu__item span {
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .np-nav .np-translate-menu__item em {
    display: none;
  }
}

/* 头像加载失败时的首字占位（脚本把破图换成这个） */
.np-avatar-fallback {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--np-primary-soft);
  color: var(--np-primary);
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0;
}

.np-member__avatar .np-avatar-fallback {
  font-size: 17px;
}

/* ==========================================================================
   16. 会员卡档位点选 + 收银台弹窗
   ========================================================================== */

/* 档位可点：主价格跟着选中档位走，省得进弹窗前还不知道自己买了哪个 */
.np-vipcard__tiers--pick .np-vipcard__tier {
  position: relative;
  cursor: pointer;
  transition: background var(--np-transition), color var(--np-transition);
}

.np-vipcard__tiers--pick .np-vipcard__tier:hover {
  background: var(--np-bg-soft);
}

.np-vipcard__tiers--pick .np-vipcard__tier.is-active {
  background: var(--np-primary-soft);
}

/* 选中档位：底部一条主色线 + 右上角对勾，不用大色块，卡片整体仍是浅色调 */
.np-vipcard__tiers--pick .np-vipcard__tier.is-active::before {
  content: '';
  position: absolute;
  left: 12%;
  right: 12%;
  bottom: 0;
  height: 2px;
  border-radius: 2px;
  background: var(--np-primary);
}

.np-vipcard__tiers--pick .np-vipcard__tier.is-active::after {
  content: '';
  position: absolute;
  top: 8px;
  right: 9px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--np-primary);
  box-shadow: 0 0 0 3px var(--np-primary-soft);
}

.np-vipcard__tiers--pick .np-vipcard__tier.is-active .np-vipcard__tier-name {
  color: var(--np-primary);
}

/* 按钮：真正的 <button>，重置掉浏览器默认外观 */
button.np-vipcard__cta {
  width: calc(100% - 32px);
  border: 0;
  cursor: pointer;
  font-family: inherit;
}

.np-vipcard__cta.is-done {
  background: var(--np-bg-soft);
  color: var(--np-text-2);
  cursor: default;
}

.np-vipcard__cta.is-done:hover {
  transform: none;
  opacity: 1;
}

.np-vipcard__note {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  margin: -8px 16px 14px;
  font-size: 11.5px;
  color: var(--np-muted);
}

.np-vipcard__note svg {
  color: var(--np-primary);
}

/* --- 弹窗骨架 --------------------------------------------------------- */
html.np-checkout-lock {
  overflow: hidden;
}

.np-checkout {
  position: fixed;
  inset: 0;
  z-index: 9998;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.np-checkout[hidden] {
  display: none;
}

.np-checkout__mask {
  position: absolute;
  inset: 0;
  background: rgba(12, 17, 24, 0.55);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  animation: np-ck-fade 0.2s ease both;
}

.np-checkout__panel {
  position: relative;
  display: flex;
  flex-direction: column;
  width: min(440px, 100%);
  max-height: min(86vh, 720px);
  border-radius: 16px;
  background: var(--np-bg);
  box-shadow: 0 24px 60px rgba(9, 15, 25, 0.28);
  overflow: hidden;
  animation: np-ck-pop 0.24s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.np-checkout.is-closing .np-checkout__panel {
  animation: np-ck-out 0.18s ease both;
}

.np-checkout.is-closing .np-checkout__mask {
  animation: np-ck-fade 0.18s ease both reverse;
}

@keyframes np-ck-fade {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes np-ck-pop {
  from { opacity: 0; transform: translateY(14px) scale(0.97); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes np-ck-out {
  from { opacity: 1; transform: translateY(0) scale(1); }
  to { opacity: 0; transform: translateY(10px) scale(0.98); }
}

.np-checkout__close {
  position: absolute;
  top: 12px;
  right: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: var(--np-bg-soft);
  color: var(--np-muted);
  cursor: pointer;
  transition: background var(--np-transition), color var(--np-transition);
}

.np-checkout__close:hover {
  background: var(--np-line);
  color: var(--np-text);
}

/* 头图：和侧栏会员卡同一套渐变，让用户一眼认出是"刚才那张卡" */
.np-checkout__head {
  position: relative;
  padding: 20px 22px 18px;
  background: linear-gradient(135deg, #ff7d59, #ff2d55);
  color: #fff;
}

.np-checkout__badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 9px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.22);
  font-size: 11.5px;
  font-weight: 600;
}

.np-checkout__title {
  margin: 10px 0 0;
  font-size: 19px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: #fff;
}

.np-checkout__account {
  display: flex;
  align-items: center;
  gap: 5px;
  margin: 6px 0 0;
  font-size: 12px;
  opacity: 0.9;
}

.np-checkout__body {
  flex: 1 1 auto;
  min-height: 0;
  padding: 18px 22px 4px;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.np-checkout__label {
  margin: 0 0 10px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--np-muted);
}

.np-checkout__step + .np-checkout__step {
  margin-top: 18px;
}

/* --- 套餐 --- */
.np-checkout__plans {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
}

.np-checkout__plan {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 11px 12px 10px;
  border: 1px solid var(--np-line);
  border-radius: 10px;
  background: var(--np-bg);
  font-family: inherit;
  text-align: left;
  cursor: pointer;
  transition: border-color var(--np-transition), background var(--np-transition), box-shadow var(--np-transition);
}

.np-checkout__plan:hover {
  border-color: var(--np-primary);
}

.np-checkout__plan.is-active {
  border-color: var(--np-primary);
  background: var(--np-primary-soft);
  box-shadow: 0 0 0 1px var(--np-primary) inset;
}

.np-checkout__plan-name {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--np-text);
}

.np-checkout__plan-price {
  font-size: 19px;
  font-weight: 800;
  line-height: 1.15;
  color: var(--np-accent);
  font-variant-numeric: tabular-nums;
}

.np-checkout__plan-meta {
  font-size: 11px;
  color: var(--np-muted);
}

.np-checkout__plan-origin {
  position: absolute;
  top: 10px;
  right: 10px;
  font-size: 11px;
  color: var(--np-muted);
}

.np-checkout__plan-origin s {
  opacity: 0.8;
}

/* --- 支付渠道 --- */
.np-checkout__gateways {
  display: grid;
  gap: 8px;
}

.np-checkout__gw {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--np-line);
  border-radius: 10px;
  background: var(--np-bg);
  font-family: inherit;
  text-align: left;
  cursor: pointer;
  transition: border-color var(--np-transition), background var(--np-transition);
}

.np-checkout__gw:hover {
  border-color: var(--np-primary);
}

.np-checkout__gw.is-active {
  border-color: var(--np-primary);
  background: var(--np-primary-soft);
}

.np-checkout__gw-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 30px;
  height: 30px;
  border-radius: 8px;
}

.np-checkout__gw--alipay .np-checkout__gw-logo {
  background: rgba(22, 119, 255, 0.1);
  color: #1677ff;
}

.np-checkout__gw--wechat .np-checkout__gw-logo {
  background: rgba(7, 193, 96, 0.12);
  color: #07c160;
}

.np-checkout__gw-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
  flex: 1 1 auto;
}

.np-checkout__gw-text strong {
  font-size: 13px;
  font-weight: 600;
  color: var(--np-text);
}

.np-checkout__gw-text small {
  margin-top: 1px;
  font-size: 11px;
  color: var(--np-muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.np-checkout__gw-tick {
  display: none;
  color: var(--np-primary);
}

.np-checkout__gw.is-active .np-checkout__gw-tick {
  display: flex;
}

.np-checkout__warn {
  margin: 0;
  padding: 10px 12px;
  border: 1px solid rgba(214, 54, 56, 0.28);
  border-radius: 8px;
  background: rgba(214, 54, 56, 0.06);
  font-size: 12.5px;
  color: var(--np-accent);
}

/* --- 底栏 --- */
.np-checkout__foot {
  flex: 0 0 auto;
  padding: 14px 22px calc(14px + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid var(--np-line);
  background: var(--np-bg);
}

.np-checkout__foot[hidden] {
  display: none;
}

.np-checkout__sum {
  display: flex;
  align-items: baseline;
  gap: 6px;
  margin-bottom: 10px;
}

.np-checkout__sum-label {
  font-size: 12.5px;
  color: var(--np-muted);
}

.np-checkout__sum-price {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--np-accent);
  font-variant-numeric: tabular-nums;
}

.np-checkout__sum-origin {
  font-size: 12px;
  color: var(--np-muted);
}

.np-checkout__submit {
  width: 100%;
  padding: 12px 0;
  border: 0;
  border-radius: 10px;
  background: linear-gradient(90deg, #4facfe, #2563eb);
  color: #fff;
  font-family: inherit;
  font-size: 14.5px;
  font-weight: 600;
  cursor: pointer;
  transition: opacity var(--np-transition), transform var(--np-transition);
}

.np-checkout__submit:hover {
  opacity: 0.94;
  transform: translateY(-1px);
}

.np-checkout__submit:disabled {
  opacity: 0.6;
  cursor: default;
  transform: none;
}

.np-checkout.is-busy .np-checkout__submit {
  position: relative;
  color: transparent;
}

.np-checkout.is-busy .np-checkout__submit::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 16px;
  height: 16px;
  margin: -8px 0 0 -8px;
  border: 2px solid rgba(255, 255, 255, 0.45);
  border-top-color: #fff;
  border-radius: 50%;
  animation: np-ck-spin 0.7s linear infinite;
}

@keyframes np-ck-spin {
  to { transform: rotate(360deg); }
}

.np-checkout__safe {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  margin: 9px 0 0;
  font-size: 11px;
  color: var(--np-muted);
}

.np-checkout__safe svg {
  flex: 0 0 auto;
  color: #2ea043;
}

/* --- 二维码步骤 --- */
.np-checkout__step--pay {
  padding-bottom: 14px;
}

.np-checkout__loading {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 46px 0;
  font-size: 13px;
  color: var(--np-muted);
}

.np-checkout__spin {
  width: 16px;
  height: 16px;
  border: 2px solid var(--np-line);
  border-top-color: var(--np-primary);
  border-radius: 50%;
  animation: np-ck-spin 0.7s linear infinite;
}

.np-checkout__qr {
  text-align: center;
}

.np-checkout__qr-head {
  display: flex;
  flex-direction: column;
  gap: 3px;
  margin-bottom: 12px;
}

.np-checkout__qr-head strong {
  font-size: 14px;
  font-weight: 600;
}

.np-checkout__qr-head small {
  font-size: 12px;
  color: var(--np-muted);
}

.np-checkout__qr-img {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px;
  border: 1px solid var(--np-line);
  border-radius: 12px;
  background: #fff;
}

.np-checkout__qr-img svg,
.np-checkout__qr-img img {
  display: block;
  width: min(216px, 58vw);
  height: auto;
  aspect-ratio: 1 / 1;
}

.np-checkout__qr-warn {
  margin: 12px 0 0;
  padding: 9px 11px;
  border-radius: 8px;
  background: rgba(245, 158, 11, 0.1);
  font-size: 11.5px;
  line-height: 1.65;
  color: #a16207;
  text-align: left;
}

.np-checkout__open-app {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  margin-top: 12px;
  padding: 12px 0;
  border: 0;
  border-radius: 10px;
  background: #1677ff;
  color: #fff;
  font-family: inherit;
  font-size: 14.5px;
  font-weight: 600;
  cursor: pointer;
}

.np-checkout__qr-status {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  margin-top: 12px;
  font-size: 12.5px;
  color: var(--np-text-2);
}

.np-checkout__qr-status.is-fail {
  color: var(--np-accent);
}

.np-checkout__pulse {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #2ea043;
  box-shadow: 0 0 0 0 rgba(46, 160, 67, 0.5);
  animation: np-ck-pulse 1.6s ease-out infinite;
}

@keyframes np-ck-pulse {
  70% { box-shadow: 0 0 0 7px rgba(46, 160, 67, 0); }
  100% { box-shadow: 0 0 0 0 rgba(46, 160, 67, 0); }
}

.np-checkout__qr-foot {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  margin-top: 12px;
}

.np-checkout__link {
  padding: 0;
  border: 0;
  background: none;
  font-family: inherit;
  font-size: 12px;
  color: var(--np-muted);
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.np-checkout__link:hover {
  color: var(--np-primary);
}

/* --- 成功态 --- */
.np-checkout__step--done {
  padding: 26px 0 30px;
}

.np-checkout__done {
  text-align: center;
}

.np-checkout__done-ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: rgba(46, 160, 67, 0.12);
  color: #2ea043;
}

.np-checkout__done strong {
  display: block;
  margin-top: 12px;
  font-size: 16px;
}

.np-checkout__done p {
  margin: 4px 0 0;
  font-size: 12.5px;
  color: var(--np-muted);
}

/* --- 手机：底部抽屉 --- */
@media (max-width: 640px) {
  .np-checkout {
    align-items: flex-end;
    padding: 0;
  }

  .np-checkout__panel {
    width: 100%;
    max-height: 90vh;
    border-radius: 18px 18px 0 0;
    animation: np-ck-up 0.26s cubic-bezier(0.22, 1, 0.36, 1) both;
  }

  .np-checkout.is-closing .np-checkout__panel {
    animation: np-ck-down 0.2s ease both;
  }

  @keyframes np-ck-up {
    from { transform: translateY(100%); }
    to { transform: translateY(0); }
  }

  @keyframes np-ck-down {
    from { transform: translateY(0); }
    to { transform: translateY(100%); }
  }

  .np-checkout__head {
    padding: 18px 18px 16px;
  }

  .np-checkout__body {
    padding: 16px 18px 4px;
  }

  .np-checkout__foot {
    padding: 12px 18px calc(12px + env(safe-area-inset-bottom, 0px));
  }

  .np-checkout__plans {
    gap: 8px;
  }

  .np-checkout__plan {
    padding: 10px 11px 9px;
  }

  .np-checkout__plan-price {
    font-size: 17px;
  }

  .np-checkout__qr-img svg,
  .np-checkout__qr-img img {
    width: min(230px, 62vw);
  }
}

/* 暗色：弹窗自带白底二维码，其余跟随令牌 */
body.np-dark .np-checkout__panel {
  background: var(--np-bg);
}

body.np-dark .np-checkout__mask {
  background: rgba(0, 0, 0, 0.66);
}

/* --- 整页收银台：手机端唤起支付宝 --- */
.np-pay__open-app {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  margin-top: 14px;
  padding: 12px 0;
  border: 0;
  border-radius: 10px;
  background: #1677ff;
  color: #fff;
  font-family: inherit;
  font-size: 14.5px;
  font-weight: 600;
  cursor: pointer;
  transition: opacity var(--np-transition);
}

.np-pay__open-app:hover {
  opacity: 0.92;
  color: #fff;
}

.np-pay__qr-warn {
  margin: 12px 0 0;
  padding: 10px 12px;
  border-radius: 8px;
  background: rgba(245, 158, 11, 0.1);
  font-size: 12px;
  line-height: 1.7;
  color: #a16207;
  text-align: left;
}

.np-pay__qr-hint {
  margin: 8px 0 0;
  font-size: 11.5px;
  color: var(--np-muted);
}

@media (prefers-reduced-motion: reduce) {
  .np-checkout__panel,
  .np-checkout__mask,
  .np-checkout__pulse,
  .np-checkout__spin,
  .np-checkout.is-busy .np-checkout__submit::after {
    animation: none !important;
  }
}

/* ==========================================================================
   17. 课程模块
   ========================================================================== */

/* --- 头部：封面 + 标题 + 价格 CTA --- */
.np-course-hero {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 22px;
  padding: 18px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
}

.np-course-hero__media {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 16 / 10;
  border-radius: calc(var(--np-radius) - 2px);
  background: var(--np-bg-soft);
  overflow: hidden;
}

.np-course-hero__cover {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.np-course-hero__ph {
  display: flex;
  color: var(--np-muted);
  opacity: 0.7;
}

.np-course-hero__tag {
  position: absolute;
  top: 10px;
  left: 10px;
  padding: 3px 9px;
  border-radius: 999px;
  background: rgba(12, 17, 24, 0.62);
  color: #fff;
  font-size: 11.5px;
  font-weight: 600;
}

.np-course-hero__tag--free {
  background: #16a34a;
}

.np-course-hero__cats {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0 0 8px;
}

.np-course-hero__cats a {
  padding: 2px 9px;
  border-radius: 999px;
  background: var(--np-primary-soft);
  color: var(--np-primary);
  font-size: 12px;
  font-weight: 600;
}

.np-course-hero__title {
  margin: 0;
  font-size: 23px;
  line-height: 1.35;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.np-course-hero__sub {
  margin: 7px 0 0;
  font-size: 13.5px;
  line-height: 1.7;
  color: var(--np-text-2);
}

.np-course-hero__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 14px;
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
  font-size: 12.5px;
  color: var(--np-muted);
}

.np-course-hero__rate {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.np-course-hero__rate b {
  color: #f59e0b;
}

.np-course-hero__teacher {
  display: flex;
  align-items: center;
  gap: 7px;
  margin: 12px 0 0;
  font-size: 13px;
}

.np-course-hero__teacher span {
  color: var(--np-muted);
  font-size: 12px;
}

.np-course-hero__avatar {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  object-fit: cover;
}

.np-course-hero__cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px dashed var(--np-line);
}

.np-course-hero__price {
  display: inline-flex;
  align-items: baseline;
  gap: 8px;
}

.np-course-hero__price b {
  font-size: 27px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--np-accent);
  font-variant-numeric: tabular-nums;
}

.np-course-hero__price s {
  font-size: 13px;
  color: var(--np-muted);
}

.np-course-hero__price--done b {
  font-size: 19px;
  color: #16a34a;
}

/* 学习进度 */
.np-course-progress {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 14px;
}

.np-course-progress__bar {
  flex: 1 1 auto;
  height: 6px;
  border-radius: 999px;
  background: var(--np-bg-soft);
  overflow: hidden;
}

.np-course-progress__bar i {
  display: block;
  width: 0;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #4facfe, #2563eb);
  transition: width 300ms ease;
}

.np-course-progress__text {
  font-size: 12px;
  color: var(--np-muted);
  white-space: nowrap;
}

.np-course-progress__go {
  padding: 4px 10px;
  border: 1px solid var(--np-line);
  border-radius: 999px;
  background: var(--np-bg);
  font-family: inherit;
  font-size: 12px;
  color: var(--np-primary);
  cursor: pointer;
}

/* --- 播放器 --- */
.np-course-player {
  margin-top: 18px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
  overflow: hidden;
}

.np-course-player__frame {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #0b1016;
}

.np-course-player__frame iframe,
.np-course-player__frame video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

.np-course-player__ph {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.np-course-player__ph-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.5;
}

.np-course-player__ph-tip {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 14px 20px;
  border-radius: 10px;
  background: rgba(12, 17, 24, 0.55);
  color: #fff;
  text-align: center;
}

.np-course-player__ph-tip p {
  margin: 0;
  font-size: 13px;
}

.np-course-player__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 14px;
  border-top: 1px solid var(--np-line);
}

.np-course-player__title {
  min-width: 0;
  font-size: 13.5px;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.np-course-player__done {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  flex: 0 0 auto;
  padding: 5px 11px;
  border: 1px solid var(--np-line);
  border-radius: 999px;
  background: var(--np-bg);
  font-family: inherit;
  font-size: 12px;
  color: var(--np-text-2);
  cursor: pointer;
  transition: color var(--np-transition), border-color var(--np-transition);
}

.np-course-player__done.is-on {
  border-color: rgba(46, 160, 67, 0.45);
  background: rgba(46, 160, 67, 0.1);
  color: #16a34a;
}

/* --- 锚点导航 --- */
.np-course-nav {
  position: sticky;
  top: var(--np-header-h, 64px);
  z-index: 5;
  display: flex;
  gap: 4px;
  margin: 18px 0 0;
  padding: 6px;
  border: 1px solid var(--np-line);
  border-radius: 999px;
  background: var(--np-bg);
  overflow-x: auto;
  scrollbar-width: none;
}

.np-course-nav::-webkit-scrollbar {
  display: none;
}

.np-course-nav a {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 7px 13px;
  border-radius: 999px;
  font-size: 13.5px;
  color: var(--np-text-2);
  white-space: nowrap;
  transition: background var(--np-transition), color var(--np-transition);
}

.np-course-nav a:hover {
  background: var(--np-bg-soft);
}

.np-course-nav a.is-active {
  background: var(--np-primary-soft);
  color: var(--np-primary);
  font-weight: 600;
}

.np-course-nav a i {
  padding: 0 5px;
  border-radius: 999px;
  background: var(--np-bg-soft);
  font-size: 11px;
  font-style: normal;
}

/* --- 通用区块 --- */
.np-course-sec {
  margin-top: 26px;
  /* 锚点跳转时留出「吸顶导航条 + 站点头部」的高度，否则标题会被压在条下面 */
  scroll-margin-top: calc(var(--np-header-h, 64px) + 74px);
}

.np-course-sec__title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 0 0 12px;
  font-size: 17px;
  font-weight: 700;
}

.np-course-sec__act {
  padding: 0;
  border: 0;
  background: none;
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--np-primary);
  cursor: pointer;
}

.np-course-sec__meta {
  margin: 0 0 12px;
  font-size: 12.5px;
  color: var(--np-muted);
}

.np-course-empty {
  padding: 26px 0;
  text-align: center;
  font-size: 13.5px;
  color: var(--np-muted);
}

.np-course-intro {
  font-size: 15px;
  line-height: 1.85;
}

.np-course-block {
  margin-top: 18px;
  padding: 14px 16px;
  border: 1px solid var(--np-line);
  border-radius: 10px;
  background: var(--np-bg-soft);
}

.np-course-block__title {
  margin: 0 0 10px;
  font-size: 14.5px;
  font-weight: 700;
}

.np-course-benefits {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 8px 18px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.np-course-benefits li {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  font-size: 13.5px;
  line-height: 1.6;
}

.np-course-benefits svg {
  flex: 0 0 auto;
  margin-top: 3px;
  color: #16a34a;
}

.np-course-audience {
  margin: 0;
  padding-left: 18px;
  font-size: 13.5px;
  line-height: 1.85;
  color: var(--np-text-2);
}

/* --- 目录 --- */
.np-course-chapter {
  margin-bottom: 10px;
  border: 1px solid var(--np-line);
  border-radius: 10px;
  background: var(--np-bg);
  overflow: hidden;
}

.np-course-chapter__head {
  display: flex;
  align-items: center;
  gap: 9px;
  width: 100%;
  padding: 12px 14px;
  border: 0;
  background: none;
  font-family: inherit;
  text-align: left;
  cursor: pointer;
}

.np-course-chapter__head:hover {
  background: var(--np-bg-soft);
}

.np-course-chapter__arrow {
  flex: 0 0 auto;
  color: var(--np-muted);
  transition: transform var(--np-transition);
}

.np-course-chapter.is-open .np-course-chapter__arrow {
  transform: rotate(90deg);
}

.np-course-chapter__no {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 22px;
  height: 22px;
  border-radius: 6px;
  background: var(--np-primary-soft);
  color: var(--np-primary);
  font-size: 12px;
  font-weight: 700;
}

.np-course-chapter__title {
  flex: 1 1 auto;
  min-width: 0;
  font-size: 14.5px;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.np-course-chapter__meta {
  flex: 0 0 auto;
  font-size: 12px;
  color: var(--np-muted);
}

.np-course-chapter__list {
  display: none;
  margin: 0;
  padding: 0 0 6px;
  list-style: none;
}

.np-course-chapter.is-open .np-course-chapter__list {
  display: block;
}

.np-course-lesson {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 14px;
  border-top: 1px dashed var(--np-line);
  cursor: pointer;
  transition: background var(--np-transition);
}

.np-course-lesson:hover {
  background: var(--np-bg-soft);
}

.np-course-lesson__no {
  flex: 0 0 auto;
  width: 32px;
  font-size: 12.5px;
  color: var(--np-muted);
  font-variant-numeric: tabular-nums;
}

.np-course-lesson__body {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-width: 0;
}

.np-course-lesson__title {
  font-size: 13.5px;
  line-height: 1.5;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.np-course-lesson__desc {
  font-size: 11.5px;
  color: var(--np-muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.np-course-lesson__tag,
.np-course-lesson__lock {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  flex: 0 0 auto;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
  white-space: nowrap;
}

.np-course-lesson__tag {
  background: var(--np-primary-soft);
  color: var(--np-primary);
  font-weight: 600;
}

.np-course-lesson__lock {
  background: var(--np-bg-soft);
  color: var(--np-muted);
}

.np-course-lesson__play {
  flex: 0 0 auto;
  color: var(--np-muted);
  opacity: 0.75;
}

.np-course-lesson__dur {
  flex: 0 0 auto;
  font-size: 12px;
  color: var(--np-muted);
  font-variant-numeric: tabular-nums;
}

.np-course-lesson__done {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 22px;
  height: 22px;
  padding: 0;
  border: 1px solid var(--np-line);
  border-radius: 50%;
  background: var(--np-bg);
  color: var(--np-muted);
  cursor: pointer;
  transition: all var(--np-transition);
}

.np-course-lesson__done:hover {
  border-color: #16a34a;
  color: #16a34a;
}

.np-course-lesson.is-done .np-course-lesson__done {
  border-color: #16a34a;
  background: #16a34a;
  color: #fff;
}

.np-course-lesson.is-done .np-course-lesson__title {
  color: var(--np-muted);
}

.np-course-lesson.is-playing {
  background: var(--np-primary-soft);
}

.np-course-lesson.is-playing .np-course-lesson__title {
  color: var(--np-primary);
  font-weight: 600;
}

.np-course-lesson.is-locked {
  cursor: pointer;
}

/* --- 资料 --- */
.np-course-files {
  margin: 0;
  padding: 0;
  list-style: none;
  border: 1px solid var(--np-line);
  border-radius: 10px;
  overflow: hidden;
}

.np-course-files li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 14px;
}

.np-course-files li + li {
  border-top: 1px dashed var(--np-line);
}

.np-course-files__ico {
  display: inline-flex;
  color: var(--np-primary);
}

.np-course-files__name {
  flex: 1 1 auto;
  min-width: 0;
  font-size: 13.5px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.np-course-files__size {
  flex: 0 0 auto;
  font-size: 12px;
  color: var(--np-muted);
}

.np-course-files__btn {
  flex: 0 0 auto;
  padding: 5px 12px;
  border: 1px solid var(--np-primary);
  border-radius: 999px;
  font-size: 12.5px;
  color: var(--np-primary);
}

.np-course-lockbox {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 26px 18px;
  border: 1px dashed var(--np-line);
  border-radius: 10px;
  background: var(--np-bg-soft);
  text-align: center;
}

.np-course-lockbox__ico {
  display: inline-flex;
  color: var(--np-muted);
}

.np-course-lockbox__text {
  margin: 0;
  font-size: 13px;
  color: var(--np-text-2);
}

/* --- 常见问题 --- */
.np-course-faq {
  border: 1px solid var(--np-line);
  border-radius: 10px;
  overflow: hidden;
}

.np-course-faq__item + .np-course-faq__item {
  border-top: 1px solid var(--np-line);
}

.np-course-faq__item summary {
  padding: 12px 14px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
}

.np-course-faq__item summary::-webkit-details-marker {
  display: none;
}

.np-course-faq__item summary::after {
  content: '+';
  float: right;
  color: var(--np-muted);
  font-weight: 400;
}

.np-course-faq__item[open] summary::after {
  content: '−';
}

.np-course-faq__a {
  padding: 0 14px 14px;
  font-size: 13.5px;
  line-height: 1.8;
  color: var(--np-text-2);
}

/* --- 评价 --- */
.np-course-rating {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px 16px;
  border: 1px solid var(--np-line);
  border-radius: 10px;
  background: var(--np-bg-soft);
}

.np-course-rating__score {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.np-course-rating__score b {
  font-size: 26px;
  font-weight: 800;
  color: #f59e0b;
  line-height: 1;
}

.np-course-rating__score span {
  font-size: 12.5px;
  color: var(--np-muted);
}

.np-course-rating__empty {
  margin: 0;
  font-size: 13px;
  color: var(--np-muted);
}

.np-stars {
  display: inline-flex;
  gap: 1px;
  color: #f59e0b;
}

.np-stars__item {
  display: inline-flex;
  opacity: 0.26;
}

.np-stars__item.is-full {
  opacity: 1;
}

.np-stars__item.is-half {
  opacity: 0.62;
}

.np-course-rate-field {
  display: flex;
  align-items: center;
  gap: 8px;
}

/* --- 侧栏 --- */
.np-course-side {
  position: sticky;
  top: calc(var(--np-header-h, 64px) + 16px);
  display: flex;
  flex-direction: column;
  gap: 14px;
  max-height: calc(100vh - var(--np-header-h, 64px) - 32px);
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
}

.np-course-buy {
  padding: 16px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
}

.np-course-buy__price {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin: 0 0 12px;
}

.np-course-buy__price b {
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--np-accent);
  font-variant-numeric: tabular-nums;
}

.np-course-buy__price s {
  font-size: 13px;
  color: var(--np-muted);
}

.np-course-buy__price--done {
  flex-direction: column;
  gap: 4px;
}

.np-course-buy__price--done b {
  font-size: 19px;
  color: #16a34a;
}

.np-course-buy__price--done span {
  font-size: 12px;
  color: var(--np-muted);
}

.np-course-buy__off {
  padding: 2px 7px;
  border-radius: 999px;
  background: rgba(214, 54, 56, 0.1);
  color: var(--np-accent);
  font-size: 11.5px;
  font-style: normal;
  font-weight: 600;
}

.np-course-buy__vip {
  display: flex;
  align-items: center;
  gap: 5px;
  margin: 10px 0 0;
  font-size: 12px;
  color: var(--np-primary);
}

.np-course-buy__off-sale {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 0;
  border-radius: 10px;
  background: var(--np-bg-soft);
  font-size: 13.5px;
  color: var(--np-muted);
}

.np-course-params {
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
}

.np-course-params li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 7px 0;
  border-top: 1px dashed var(--np-line);
  font-size: 12.5px;
}

.np-course-params li span {
  color: var(--np-muted);
}

.np-course-params li b {
  font-weight: 600;
  text-align: right;
}

.np-course-buy__notice {
  margin: 12px 0 0;
  padding: 9px 11px;
  border-radius: 8px;
  background: var(--np-bg-soft);
  font-size: 11.5px;
  line-height: 1.7;
  color: var(--np-muted);
}

.np-course-teacher__head {
  display: flex;
  align-items: center;
  gap: 10px;
}

.np-course-teacher__avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
}

.np-course-teacher__head span {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.np-course-teacher__head i {
  font-size: 12px;
  font-style: normal;
  color: var(--np-muted);
}

.np-course-teacher__desc {
  margin: 10px 0 0;
  font-size: 12.5px;
  line-height: 1.75;
  color: var(--np-text-2);
}

.np-course-rel__list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.np-course-rel__item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
}

.np-course-rel__item + .np-course-rel__item {
  border-top: 1px dashed var(--np-line);
}

.np-course-rel__thumb {
  display: block;
  flex: 0 0 auto;
  width: 78px;
  height: 52px;
  border-radius: 6px;
  background: var(--np-bg-soft);
  overflow: hidden;
}

.np-course-rel__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.np-course-rel__body {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.np-course-rel__body b {
  font-size: 13px;
  font-weight: 600;
  line-height: 1.45;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.np-course-rel__body i {
  font-size: 11.5px;
  font-style: normal;
  color: var(--np-accent);
}

/* --- 小屏底部购买条 --- */
.np-course-buybar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 80;
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 14px calc(10px + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid var(--np-line);
  background: var(--np-bg);
  box-shadow: 0 -6px 22px rgba(9, 15, 25, 0.1);
  transform: translateY(115%);
  transition: transform 260ms cubic-bezier(0.32, 0.72, 0, 1);
}

.np-course-buybar.is-show {
  transform: translateY(0);
}

.np-course-buybar__price {
  display: inline-flex;
  align-items: baseline;
  gap: 7px;
  min-width: 0;
}

.np-course-buybar__price b {
  font-size: 21px;
  font-weight: 800;
  color: var(--np-accent);
  font-variant-numeric: tabular-nums;
}

.np-course-buybar__price s {
  font-size: 12px;
  color: var(--np-muted);
}

/* --- 课程列表 --- */
.np-course-archive {
  padding: 4px 0 12px;
}

.np-course-archive__title {
  margin: 0;
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.np-course-archive__desc {
  margin: 8px 0 0;
  font-size: 13.5px;
  line-height: 1.8;
  color: var(--np-text-2);
}

.np-course-archive__count {
  margin: 6px 0 0;
  font-size: 12.5px;
  color: var(--np-muted);
}

.np-course-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}

.np-course-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 12px;
  border: 1px solid var(--np-line);
  border-radius: 999px;
  font-size: 13px;
  color: var(--np-text-2);
  transition: all var(--np-transition);
}

.np-course-chip:hover {
  border-color: var(--np-primary);
  color: var(--np-primary);
}

.np-course-chip.is-active {
  border-color: var(--np-primary);
  background: var(--np-primary);
  color: #fff;
}

.np-course-chip i {
  font-size: 11px;
  font-style: normal;
  opacity: 0.7;
}

.np-course-sort {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--np-line);
}

.np-course-sort__item {
  padding: 5px 11px;
  border-radius: 6px;
  font-size: 12.5px;
  color: var(--np-muted);
}

.np-course-sort__item:hover {
  background: var(--np-bg-soft);
  color: var(--np-text);
}

.np-course-sort__item.is-active {
  background: var(--np-primary-soft);
  color: var(--np-primary);
  font-weight: 600;
}

.np-course-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.np-course-grid--2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.np-course-grid--3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.np-course-grid--4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.np-course-card {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
  overflow: hidden;
  transition: transform var(--np-transition), box-shadow var(--np-transition), border-color var(--np-transition);
}

.np-course-card:hover {
  transform: translateY(-2px);
  border-color: var(--np-primary);
  box-shadow: var(--np-shadow);
}

.np-course-card__media {
  position: relative;
  display: block;
  aspect-ratio: 16 / 9;
  background: var(--np-bg-soft);
  overflow: hidden;
}

.np-course-card__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.np-course-card__ph {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--np-muted);
  opacity: 0.7;
}

.np-course-card__level {
  position: absolute;
  left: 8px;
  bottom: 8px;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(12, 17, 24, 0.6);
  color: #fff;
  font-size: 11px;
}

.np-course-card__tag--free {
  position: absolute;
  top: 8px;
  right: 8px;
  padding: 2px 8px;
  border-radius: 999px;
  background: #16a34a;
  color: #fff;
  font-size: 11px;
  font-weight: 600;
}

.np-course-card__body {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1 1 auto;
  padding: 12px 13px 13px;
}

.np-course-card__title {
  margin: 0;
  font-size: 15px;
  line-height: 1.45;
  font-weight: 600;
}

.np-course-card__title a {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.np-course-card__sub {
  margin: 0;
  font-size: 12.5px;
  line-height: 1.6;
  color: var(--np-muted);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.np-course-card__meta {
  margin: 0;
  font-size: 11.5px;
  color: var(--np-muted);
}

.np-course-card__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: auto;
  padding-top: 10px;
  border-top: 1px dashed var(--np-line);
}

.np-course-card__price {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
}

.np-course-card__price b {
  font-size: 18px;
  font-weight: 800;
  color: var(--np-accent);
  font-variant-numeric: tabular-nums;
}

.np-course-card__price s {
  font-size: 11.5px;
  color: var(--np-muted);
}

.np-course-card__price--free {
  font-size: 15px;
  font-weight: 700;
  color: #16a34a;
}

.np-course-card__go {
  flex: 0 0 auto;
  font-size: 12.5px;
  color: var(--np-primary);
}

/* --- 收银台：固定商品（课程 / 单篇）摘要 --- */
.np-checkout__item-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid var(--np-line);
  border-radius: 10px;
  background: var(--np-bg-soft);
}

.np-checkout__item-main {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

.np-checkout__item-name {
  font-size: 13.5px;
  font-weight: 600;
}

.np-checkout__item-desc {
  font-size: 11.5px;
  line-height: 1.6;
  color: var(--np-muted);
}

.np-checkout__item-price {
  flex: 0 0 auto;
  font-size: 19px;
  font-weight: 800;
  color: var(--np-accent);
  font-variant-numeric: tabular-nums;
}

/* --- 响应式 --- */
@media (max-width: 1024px) {
  .np-course-hero {
    grid-template-columns: 240px minmax(0, 1fr);
  }

  .np-course-grid--4 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  .np-course-hero {
    grid-template-columns: 1fr;
  }

  .np-course-hero__media {
    aspect-ratio: 16 / 9;
  }

  .np-course-side {
    position: static;
    max-height: none;
    overflow: visible;
  }

  .np-course-buybar {
    display: flex;
  }

  body.has-np-course-bar .np-content {
    padding-bottom: 78px;
  }

  .np-course-grid,
  .np-course-grid--2,
  .np-course-grid--3,
  .np-course-grid--4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .np-course-hero {
    padding: 14px;
  }

  .np-course-hero__title {
    font-size: 20px;
  }

  .np-course-sec {
    margin-top: 20px;
  }

  .np-course-lesson {
    padding: 10px 12px;
  }

  .np-course-lesson__desc {
    display: none;
  }

  .np-course-grid,
  .np-course-grid--2,
  .np-course-grid--3,
  .np-course-grid--4 {
    grid-template-columns: minmax(0, 1fr);
  }

  .np-course-rating {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
}

/* 暗色：封面占位与播放器在深色下别糊成一片 */
body.np-dark .np-course-player__frame {
  background: #000;
}

body.np-dark .np-course-card__level {
  background: rgba(0, 0, 0, 0.66);
}

body.np-dark .np-course-buybar {
  box-shadow: 0 -6px 22px rgba(0, 0, 0, 0.45);
}

@media (prefers-reduced-motion: reduce) {
  .np-course-card,
  .np-course-buybar,
  .np-course-progress__bar i {
    transition: none !important;
  }
}

/* ==========================================================================
   18. 商城模块
   ========================================================================== */

/* --- 面包屑 --- */
.np-shop-crumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  padding: 10px 0 2px;
  font-size: 12.5px;
  color: var(--np-muted);
}

.np-shop-crumb a {
  color: var(--np-muted);
}

.np-shop-crumb a:hover {
  color: var(--np-primary);
}

.np-shop-crumb__sep {
  opacity: 0.5;
}

.np-shop-crumb__now {
  color: var(--np-text-2);
}

/* --- 商城头部 --- */
.np-shop-hero {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 0 14px;
  border-bottom: 1px solid var(--np-line);
}

.np-shop-hero__title {
  margin: 0;
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.015em;
}

.np-shop-hero__desc {
  margin: 6px 0 0;
  font-size: 13.5px;
  line-height: 1.7;
  color: var(--np-text-2);
}

.np-shop-hero__count {
  margin: 5px 0 0;
  font-size: 12.5px;
  color: var(--np-muted);
}

.np-shop-hero__cart {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex: 0 0 auto;
  padding: 8px 14px;
  border: 1px solid var(--np-line);
  border-radius: 999px;
  font-size: 13px;
  color: var(--np-text-2);
  transition: border-color var(--np-transition), color var(--np-transition);
}

.np-shop-hero__cart:hover {
  border-color: var(--np-primary);
  color: var(--np-primary);
}

.np-shop-hero__cart b {
  min-width: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--np-accent);
  color: #fff;
  font-size: 11.5px;
  font-weight: 600;
  text-align: center;
}

/* --- 服务保障条 --- */
.np-shop-service {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 10px;
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
}

.np-shop-service li {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 11px 13px;
  border: 1px solid var(--np-line);
  border-radius: 10px;
  background: var(--np-bg-soft);
}

.np-shop-service__ico {
  display: inline-flex;
  flex: 0 0 auto;
  color: var(--np-primary);
}

.np-shop-service span {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.np-shop-service strong {
  font-size: 13px;
  font-weight: 600;
}

.np-shop-service small {
  margin-top: 1px;
  font-size: 11.5px;
  color: var(--np-muted);
}

/* --- 筛选 / 排序 --- */
.np-shop-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 18px 0 0;
}

.np-shop-tabs,
.np-shop-sort {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.np-shop-tab {
  padding: 6px 14px;
  border: 1px solid var(--np-line);
  border-radius: 999px;
  font-size: 13px;
  color: var(--np-text-2);
  transition: all var(--np-transition);
}

.np-shop-tab:hover {
  border-color: var(--np-primary);
  color: var(--np-primary);
}

.np-shop-tab.is-active {
  border-color: var(--np-primary);
  background: var(--np-primary);
  color: #fff;
  font-weight: 600;
}

.np-shop-sort__item {
  padding: 5px 10px;
  border-radius: 6px;
  font-size: 12.5px;
  color: var(--np-muted);
}

.np-shop-sort__item:hover {
  background: var(--np-bg-soft);
  color: var(--np-text);
}

.np-shop-sort__item.is-active {
  background: var(--np-primary-soft);
  color: var(--np-primary);
  font-weight: 600;
}

.np-shop-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 12px 0 16px;
}

.np-shop-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 12px;
  border: 1px solid var(--np-line);
  border-radius: 999px;
  font-size: 12.5px;
  color: var(--np-text-2);
  transition: all var(--np-transition);
}

.np-shop-chip:hover {
  border-color: var(--np-primary);
  color: var(--np-primary);
}

.np-shop-chip.is-active {
  border-color: var(--np-primary);
  background: var(--np-primary-soft);
  color: var(--np-primary);
  font-weight: 600;
}

.np-shop-chip i {
  font-size: 11px;
  font-style: normal;
  opacity: 0.65;
}

/* --- 商品网格 --- */
.np-shop-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.np-shop-grid--2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.np-shop-grid--3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.np-shop-card {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
  overflow: hidden;
  transition: transform var(--np-transition), box-shadow var(--np-transition), border-color var(--np-transition);
}

.np-shop-card:hover {
  transform: translateY(-2px);
  border-color: var(--np-primary);
  box-shadow: var(--np-shadow);
}

.np-shop-card__media {
  position: relative;
  display: block;
  aspect-ratio: 1 / 1;
  background: var(--np-bg-soft);
  overflow: hidden;
}

.np-shop-card__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 320ms ease;
}

.np-shop-card:hover .np-shop-card__img {
  transform: scale(1.03);
}

.np-shop-card__ph {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--np-muted);
  opacity: 0.7;
}

.np-shop-card__off,
.np-shop-card__sold {
  position: absolute;
  top: 8px;
  padding: 2px 8px;
  border-radius: 999px;
  color: #fff;
  font-size: 11px;
  font-weight: 600;
}

.np-shop-card__off {
  left: 8px;
  background: var(--np-accent);
}

.np-shop-card__sold {
  right: 8px;
  background: rgba(12, 17, 24, 0.62);
}

.np-shop-card__body {
  display: flex;
  flex-direction: column;
  gap: 5px;
  flex: 1 1 auto;
  padding: 11px 12px 12px;
}

.np-shop-card__title {
  margin: 0;
  font-size: 14.5px;
  line-height: 1.45;
  font-weight: 600;
}

.np-shop-card__title a {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.np-shop-card__sub {
  margin: 0;
  font-size: 12.5px;
  line-height: 1.6;
  color: var(--np-muted);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.np-shop-card__badge {
  display: inline-block;
  align-self: flex-start;
  margin: 0;
  padding: 2px 7px;
  border-radius: 4px;
  background: rgba(214, 54, 56, 0.08);
  color: var(--np-accent);
  font-size: 11px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 100%;
}

.np-shop-card__foot {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  margin-top: auto;
  padding-top: 9px;
}

.np-shop-card__price {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
}

.np-shop-card__price b {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--np-accent);
  font-variant-numeric: tabular-nums;
}

.np-shop-card__price s {
  font-size: 11.5px;
  color: var(--np-muted);
}

.np-shop-card__sales {
  font-size: 11.5px;
  color: var(--np-muted);
  white-space: nowrap;
}

.np-shop-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  padding: 46px 0 60px;
  text-align: center;
}

.np-shop-empty p {
  margin: 0;
  max-width: 460px;
  font-size: 13.5px;
  line-height: 1.75;
  color: var(--np-muted);
}

.np-shop-empty-sm {
  padding: 20px 0;
  text-align: center;
  font-size: 13px;
  color: var(--np-muted);
}

/* --- 商品详情 --- */
.np-product {
  display: grid;
  grid-template-columns: 440px minmax(0, 1fr);
  gap: 26px;
  margin-top: 16px;
}

.np-product__stage {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 1 / 1;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg-soft);
  overflow: hidden;
}

.np-product__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.np-product__ph {
  display: flex;
  color: var(--np-muted);
  opacity: 0.65;
}

.np-product__off {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--np-accent);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
}

.np-product__thumbs {
  display: flex;
  gap: 8px;
  margin-top: 10px;
  overflow-x: auto;
  scrollbar-width: none;
}

.np-product__thumbs::-webkit-scrollbar {
  display: none;
}

.np-product__thumb {
  flex: 0 0 auto;
  width: 66px;
  height: 66px;
  padding: 0;
  border: 1px solid var(--np-line);
  border-radius: 8px;
  background: var(--np-bg);
  overflow: hidden;
  cursor: pointer;
  opacity: 0.72;
  transition: opacity var(--np-transition), border-color var(--np-transition);
}

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

.np-product__thumb:hover {
  opacity: 1;
}

.np-product__thumb.is-active {
  opacity: 1;
  border-color: var(--np-primary);
}

.np-product__title {
  margin: 0;
  font-size: 24px;
  line-height: 1.35;
  font-weight: 700;
  letter-spacing: -0.015em;
}

.np-product__sub {
  margin: 8px 0 0;
  font-size: 13.5px;
  line-height: 1.7;
  color: var(--np-text-2);
}

.np-product__badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin: 10px 0 0;
  padding: 3px 10px;
  border-radius: 6px;
  background: rgba(214, 54, 56, 0.08);
  color: var(--np-accent);
  font-size: 12px;
  font-weight: 600;
}

.np-product__pricebox {
  margin-top: 16px;
  padding: 14px 16px;
  border-radius: 10px;
  background: linear-gradient(135deg, rgba(214, 54, 56, 0.07), rgba(214, 54, 56, 0.02));
}

.np-product__price {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 10px;
  margin: 0;
}

.np-product__price b {
  font-size: 30px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--np-accent);
  font-variant-numeric: tabular-nums;
}

.np-product__price s {
  font-size: 13.5px;
  color: var(--np-muted);
}

.np-product__tagoff {
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--np-accent);
  color: #fff;
  font-size: 11.5px;
  font-style: normal;
  font-weight: 700;
}

.np-product__meta {
  margin: 6px 0 0;
  font-size: 12.5px;
  color: var(--np-muted);
}

/* 规格 */
.np-product__specs {
  margin-top: 16px;
}

.np-product__spec + .np-product__spec {
  margin-top: 12px;
}

.np-product__spec-label {
  display: block;
  margin-bottom: 7px;
  font-size: 13px;
  font-weight: 600;
  color: var(--np-text-2);
}

.np-product__spec-vals {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.np-product__spec-val {
  display: inline-flex;
  align-items: baseline;
  gap: 4px;
  padding: 7px 14px;
  border: 1px solid var(--np-line);
  border-radius: 8px;
  background: var(--np-bg);
  font-family: inherit;
  font-size: 13px;
  color: var(--np-text-2);
  cursor: pointer;
  transition: all var(--np-transition);
}

.np-product__spec-val:hover {
  border-color: var(--np-primary);
  color: var(--np-primary);
}

.np-product__spec-val.is-active {
  border-color: var(--np-primary);
  background: var(--np-primary-soft);
  color: var(--np-primary);
  font-weight: 600;
}

.np-product__spec-val i {
  font-size: 11px;
  font-style: normal;
  opacity: 0.85;
}

/* 数量 */
.np-product__qty {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 18px;
}

.np-product__qty-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--np-text-2);
}

.np-product__stepper {
  display: inline-flex;
  align-items: stretch;
  border: 1px solid var(--np-line);
  border-radius: 8px;
  overflow: hidden;
}

.np-product__stepper button {
  width: 34px;
  border: 0;
  background: var(--np-bg-soft);
  font-family: inherit;
  font-size: 16px;
  color: var(--np-text-2);
  cursor: pointer;
  transition: background var(--np-transition);
}

.np-product__stepper button:hover {
  background: var(--np-line);
}

.np-product__stepper input {
  width: 54px;
  padding: 7px 0;
  border: 0;
  border-left: 1px solid var(--np-line);
  border-right: 1px solid var(--np-line);
  background: var(--np-bg);
  font-family: inherit;
  font-size: 14px;
  color: var(--np-text);
  text-align: center;
  -moz-appearance: textfield;
}

.np-product__stepper input::-webkit-outer-spin-button,
.np-product__stepper input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.np-product__stock {
  font-size: 12.5px;
  color: var(--np-muted);
}

/* 按钮 */
.np-product__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}

.np-product__actions .np-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 12px 22px;
}

.np-product__off-sale {
  display: inline-flex;
  align-items: center;
  padding: 12px 22px;
  border-radius: 8px;
  background: var(--np-bg-soft);
  font-size: 14px;
  color: var(--np-muted);
}

.np-product__owned {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin: 14px 0 0;
  font-size: 12.5px;
  color: #16a34a;
}

.np-product__service {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 16px;
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
}

.np-product__service li {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  color: var(--np-muted);
}

.np-product__service svg {
  color: var(--np-primary);
}

/* 详情 Tab */
.np-product__tabs {
  margin-top: 30px;
}

.np-shop-nav {
  display: flex;
  gap: 4px;
  padding: 5px;
  border: 1px solid var(--np-line);
  border-radius: 10px;
  background: var(--np-bg-soft);
  overflow-x: auto;
  scrollbar-width: none;
}

.np-shop-nav::-webkit-scrollbar {
  display: none;
}

.np-shop-nav button {
  flex: 0 0 auto;
  padding: 8px 18px;
  border: 0;
  border-radius: 7px;
  background: none;
  font-family: inherit;
  font-size: 13.5px;
  color: var(--np-text-2);
  white-space: nowrap;
  cursor: pointer;
  transition: background var(--np-transition), color var(--np-transition);
}

.np-shop-nav button.is-active {
  background: var(--np-bg);
  color: var(--np-primary);
  font-weight: 600;
  box-shadow: 0 1px 3px rgba(9, 15, 25, 0.08);
}

.np-shop-panel {
  padding: 18px 0 0;
}

.np-shop-panel[hidden] {
  display: none;
}

.np-product__content {
  font-size: 15px;
  line-height: 1.85;
}

.np-product__params {
  width: 100%;
  border-collapse: collapse;
  border: 1px solid var(--np-line);
  border-radius: 10px;
  overflow: hidden;
}

.np-product__params th,
.np-product__params td {
  padding: 11px 14px;
  border-bottom: 1px solid var(--np-line);
  font-size: 13.5px;
  text-align: left;
}

.np-product__params tr:last-child th,
.np-product__params tr:last-child td {
  border-bottom: 0;
}

.np-product__params th {
  width: 160px;
  background: var(--np-bg-soft);
  font-weight: 600;
  color: var(--np-text-2);
}

.np-shop-related {
  margin-top: 34px;
}

.np-shop-related__title {
  margin: 0 0 14px;
  font-size: 17px;
  font-weight: 700;
}

/* --- 购物车 --- */
.np-cart-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 0 16px;
  border-bottom: 1px solid var(--np-line);
}

.np-cart-head__title {
  margin: 0;
  font-size: 24px;
  font-weight: 700;
}

.np-cart-head__clear {
  padding: 0;
  border: 0;
  background: none;
  font-family: inherit;
  font-size: 12.5px;
  color: var(--np-muted);
  cursor: pointer;
}

.np-cart-head__clear:hover {
  color: var(--np-accent);
}

.np-cart-issues {
  margin: 14px 0 0;
  padding: 10px 14px;
  border: 1px solid rgba(245, 158, 11, 0.3);
  border-radius: 8px;
  background: rgba(245, 158, 11, 0.08);
}

.np-cart-issues p {
  margin: 0;
  font-size: 12.5px;
  line-height: 1.7;
  color: #a16207;
}

.np-cart {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 20px;
  margin-top: 16px;
  align-items: start;
}

.np-cart__list {
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
  overflow: hidden;
}

.np-cart__row {
  display: grid;
  grid-template-columns: 78px minmax(0, 1fr) auto 96px 34px;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
}

.np-cart__row + .np-cart__row {
  border-top: 1px dashed var(--np-line);
}

.np-cart__thumb {
  display: block;
  width: 78px;
  height: 78px;
  border-radius: 8px;
  background: var(--np-bg-soft);
  overflow: hidden;
}

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

.np-cart__name {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.45;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.np-cart__spec {
  margin: 3px 0 0;
  font-size: 12px;
  color: var(--np-muted);
}

.np-cart__price {
  margin: 4px 0 0;
  font-size: 13px;
  color: var(--np-muted);
}

.np-cart__qty {
  display: inline-flex;
  align-items: stretch;
  border: 1px solid var(--np-line);
  border-radius: 8px;
  overflow: hidden;
}

.np-cart__qty button {
  width: 28px;
  border: 0;
  background: var(--np-bg-soft);
  font-family: inherit;
  font-size: 15px;
  color: var(--np-text-2);
  cursor: pointer;
}

.np-cart__qty button:hover {
  background: var(--np-line);
}

.np-cart__qty input {
  width: 44px;
  padding: 6px 0;
  border: 0;
  border-left: 1px solid var(--np-line);
  border-right: 1px solid var(--np-line);
  background: var(--np-bg);
  font-family: inherit;
  font-size: 13.5px;
  text-align: center;
  -moz-appearance: textfield;
}

.np-cart__qty input::-webkit-outer-spin-button,
.np-cart__qty input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.np-cart__sum {
  font-size: 15px;
  font-weight: 700;
  color: var(--np-accent);
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.np-cart__del {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: none;
  color: var(--np-muted);
  cursor: pointer;
  transition: background var(--np-transition), color var(--np-transition);
}

.np-cart__del:hover {
  background: rgba(214, 54, 56, 0.1);
  color: var(--np-accent);
}

.np-cart__side {
  position: sticky;
  top: calc(var(--np-header-h, 64px) + 16px);
}

.np-cart__box {
  padding: 16px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
}

.np-cart__box-title {
  margin: 0 0 12px;
  font-size: 15px;
  font-weight: 700;
}

.np-cart__sum-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.np-cart__sum-list li {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  padding: 7px 0;
  border-top: 1px dashed var(--np-line);
  font-size: 13px;
  color: var(--np-text-2);
}

.np-cart__sum-list li b {
  font-weight: 600;
  color: var(--np-text);
}

.np-cart__tip {
  margin: 8px 0 0;
  font-size: 12px;
  color: #a16207;
}

.np-cart__total {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin: 12px 0 14px;
  padding-top: 12px;
  border-top: 1px solid var(--np-line);
}

.np-cart__total span {
  font-size: 13px;
  color: var(--np-text-2);
}

.np-cart__total b {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--np-accent);
  font-variant-numeric: tabular-nums;
}

.np-cart__off {
  display: block;
  padding: 12px 0;
  border-radius: 8px;
  background: var(--np-bg-soft);
  font-size: 13.5px;
  color: var(--np-muted);
  text-align: center;
}

.np-cart__back {
  display: block;
  margin-top: 12px;
  font-size: 12.5px;
  color: var(--np-muted);
  text-align: center;
}

.np-cart__back:hover {
  color: var(--np-primary);
}

.np-cart-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  padding: 60px 0 80px;
  color: var(--np-muted);
  text-align: center;
}

.np-cart-empty p {
  margin: 0;
  font-size: 14px;
}

/* --- 移动端底部操作条 --- */
.np-product-bar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 80;
  display: none;
  align-items: center;
  gap: 10px;
  padding: 10px 14px calc(10px + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid var(--np-line);
  background: var(--np-bg);
  box-shadow: 0 -6px 22px rgba(9, 15, 25, 0.1);
  transform: translateY(115%);
  transition: transform 260ms cubic-bezier(0.32, 0.72, 0, 1);
}

.np-product-bar.is-show {
  transform: translateY(0);
}

.np-product-bar .np-btn {
  flex: 1 1 auto;
  padding: 11px 0;
}

.np-product-bar__cart {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 42px;
  height: 40px;
  border: 1px solid var(--np-line);
  border-radius: 10px;
  color: var(--np-text-2);
}

.np-product-bar__cart b {
  position: absolute;
  top: -5px;
  right: -5px;
  min-width: 17px;
  padding: 0 4px;
  border-radius: 999px;
  background: var(--np-accent);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  text-align: center;
}

/* --- 头部购物车入口 --- */
.np-cart-toggle {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 8px;
  color: var(--np-text-2);
  transition: background var(--np-transition), color var(--np-transition);
}

.np-cart-toggle:hover {
  background: var(--np-bg-soft);
  color: var(--np-primary);
}

.np-cart-toggle__badge {
  position: absolute;
  top: -2px;
  right: -2px;
  min-width: 16px;
  padding: 0 4px;
  border-radius: 999px;
  background: var(--np-accent);
  color: #fff;
  font-size: 10.5px;
  font-weight: 600;
  line-height: 16px;
  text-align: center;
}

/* --- 轻提示 --- */
.np-shop-toast {
  position: fixed;
  left: 50%;
  bottom: 32px;
  z-index: 9999;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 18px;
  border-radius: 10px;
  background: rgba(17, 24, 34, 0.94);
  color: #fff;
  font-size: 13.5px;
  box-shadow: 0 10px 30px rgba(9, 15, 25, 0.28);
  transform: translate(-50%, 16px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 200ms ease, transform 200ms ease;
}

.np-shop-toast.is-show {
  transform: translate(-50%, 0);
  opacity: 1;
  pointer-events: auto;
}

.np-shop-toast__link {
  color: #7ec8ff;
  font-weight: 600;
  white-space: nowrap;
}

/* --- 响应式 --- */
@media (max-width: 1024px) {
  .np-product {
    grid-template-columns: 340px minmax(0, 1fr);
  }

  .np-shop-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .np-cart {
    grid-template-columns: minmax(0, 1fr);
  }

  .np-cart__side {
    position: static;
  }
}

@media (max-width: 782px) {
  .np-product {
    grid-template-columns: minmax(0, 1fr);
  }

  .np-product-bar {
    display: flex;
  }

  /* 1.8.34 手机端：页面内电脑版的规格 / 数量 / 加购 / 立即购买收进底部操作条 +
     规格弹窗，避免两套下单控件重复出现。DOM 必须保留——shop.js 缓存了这些节点，
     buy-panel.js 靠代理点击它们算价，删掉会让弹窗选规格失效，所以只做视觉隐藏。
     售罄 / 未开放购买没有 --buyable 标记，状态文案照常显示。 */
  body.np-product-mobile-clean .np-product__specs,
  body.np-product-mobile-clean .np-product__qty,
  body.np-product-mobile-clean .np-product__login-tip,
  body.np-product-mobile-clean .np-product__actions--buyable {
    display: none !important;
  }

  body.has-np-shop-bar {
    padding-bottom: 78px;
  }

  .np-shop-hero {
    flex-direction: column;
    align-items: flex-start;
  }

  .np-shop-service {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .np-shop-grid,
  .np-shop-grid--2,
  .np-shop-grid--3 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .np-cart__row {
    grid-template-columns: 62px minmax(0, 1fr) auto;
    grid-template-areas:
      "thumb body del"
      "thumb qty sum";
    row-gap: 8px;
  }

  .np-cart__thumb {
    grid-area: thumb;
    width: 62px;
    height: 62px;
  }

  .np-cart__body {
    grid-area: body;
  }

  .np-cart__qty {
    grid-area: qty;
  }

  .np-cart__sum {
    grid-area: sum;
  }

  .np-cart__del {
    grid-area: del;
  }
}

@media (max-width: 560px) {
  .np-shop-grid,
  .np-shop-grid--2,
  .np-shop-grid--3,
  .np-shop-grid--4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .np-product__title {
    font-size: 20px;
  }

  .np-product__price b {
    font-size: 26px;
  }

  .np-shop-service {
    grid-template-columns: minmax(0, 1fr);
  }
}

body.np-dark .np-shop-toast {
  background: rgba(0, 0, 0, 0.9);
}

body.np-dark .np-shop-nav button.is-active {
  box-shadow: none;
}

@media (prefers-reduced-motion: reduce) {
  .np-shop-card,
  .np-shop-card__img,
  .np-product-bar {
    transition: none !important;
  }
}

/* ==========================================================================
   19. 刷题模块
   ========================================================================== */

/* --- 面包屑 --- */
.np-quiz-crumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  padding: 10px 0 2px;
  font-size: 12.5px;
  color: var(--np-muted);
}

.np-quiz-crumb a:hover {
  color: var(--np-primary);
}

.np-quiz-crumb__sep {
  opacity: 0.5;
}

.np-quiz-crumb__now {
  color: var(--np-text-2);
}

/* --- 题库列表 --- */
.np-quiz-archive {
  padding: 14px 0 6px;
}

.np-quiz-archive__title {
  margin: 0 0 6px;
  font-size: 26px;
}

.np-quiz-archive__desc {
  color: var(--np-text-2);
  font-size: 14px;
}

.np-quiz-archive__count {
  margin: 6px 0 0;
  color: var(--np-muted);
  font-size: 13px;
}

.np-quiz-archive__go {
  display: inline-block;
  margin-top: 10px;
  padding: 7px 16px;
  border-radius: var(--np-radius-sm);
  background: var(--np-primary);
  color: #fff;
  font-size: 14px;
}

.np-quiz-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 12px 0;
}

.np-quiz-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 14px;
  border: 1px solid var(--np-line);
  border-radius: 999px;
  background: var(--np-bg);
  color: var(--np-text-2);
  font-size: 13px;
}

.np-quiz-chip i {
  font-style: normal;
  color: var(--np-muted);
  font-size: 12px;
}

.np-quiz-chip.is-active {
  border-color: var(--np-primary);
  background: var(--np-primary-soft);
  color: var(--np-primary);
}

.np-quiz-grid {
  display: grid;
  gap: 18px;
  padding: 8px 0 20px;
}

.np-quiz-grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.np-quiz-grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.np-quiz-grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.np-quiz-card {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
  overflow: hidden;
  transition: transform var(--np-transition), box-shadow var(--np-transition);
}

.np-quiz-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--np-shadow);
}

.np-quiz-card__cover {
  position: relative;
  display: block;
  aspect-ratio: 16 / 9;
  background: linear-gradient(135deg, var(--np-primary-soft), var(--np-bg-soft));
  overflow: hidden;
}

.np-quiz-card__cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.np-quiz-card__letter {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  color: var(--np-primary);
  font-size: 40px;
  font-weight: 700;
}

.np-quiz-card__badge {
  position: absolute;
  top: 10px;
  left: 10px;
  padding: 3px 9px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  font-size: 12px;
}

.np-quiz-card__badge--pay {
  background: var(--np-accent);
}

.np-quiz-card__body {
  display: flex;
  flex-direction: column;
  gap: 7px;
  padding: 13px 15px 15px;
}

.np-quiz-card__cat {
  color: var(--np-primary);
  font-size: 12px;
}

.np-quiz-card__title {
  margin: 0;
  font-size: 16px;
  line-height: 1.45;
}

.np-quiz-card__title a {
  color: var(--np-text);
}

.np-quiz-card__sub {
  margin: 0;
  color: var(--np-muted);
  font-size: 13px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.np-quiz-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  color: var(--np-muted);
  font-size: 12.5px;
}

.np-quiz-card__meta strong {
  color: var(--np-text);
}

.np-quiz-card__go {
  margin-top: 4px;
  padding: 8px 0;
  border-radius: var(--np-radius-sm);
  background: var(--np-primary-soft);
  color: var(--np-primary);
  text-align: center;
  font-size: 14px;
}

.np-quiz-empty {
  padding: 40px 0;
  color: var(--np-muted);
  text-align: center;
}

/* --- 题库详情 --- */
.np-quiz-hero {
  display: grid;
  grid-template-columns: minmax(0, 320px) minmax(0, 1fr);
  gap: 24px;
  padding: 16px 0 20px;
}

.np-quiz-hero__media {
  border-radius: var(--np-radius);
  overflow: hidden;
  background: var(--np-bg-soft);
}

.np-quiz-hero__img {
  width: 100%;
  height: auto;
  display: block;
}

.np-quiz-hero__title {
  margin: 0 0 8px;
  font-size: 27px;
  line-height: 1.3;
}

.np-quiz-hero__sub {
  margin: 0 0 12px;
  color: var(--np-text-2);
  font-size: 14.5px;
}

.np-quiz-hero__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin: 0 0 12px;
  padding: 0;
  list-style: none;
  color: var(--np-muted);
  font-size: 13px;
}

.np-quiz-hero__meta strong {
  color: var(--np-text);
  font-size: 18px;
  margin-right: 3px;
}

.np-quiz-hero__types {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin: 0 0 16px;
  padding: 0;
  list-style: none;
  color: var(--np-text-2);
  font-size: 13px;
}

.np-quiz-hero__types li {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.np-quiz-hero__types i {
  font-style: normal;
  color: var(--np-muted);
}

.np-quiz-hero__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--np-primary);
}

.np-quiz-hero__dot--multi { background: #0f8a5f; }
.np-quiz-hero__dot--judge { background: #dba617; }
.np-quiz-hero__dot--fill { background: #7b4fd8; }
.np-quiz-hero__dot--essay { background: #d63638; }

.np-quiz-hero__ops {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.np-quiz-single__content {
  padding: 12px 0 20px;
  font-size: 15.5px;
  line-height: 1.85;
}

.np-quiz-off {
  display: inline-block;
  padding: 8px 16px;
  border-radius: var(--np-radius-sm);
  background: var(--np-bg-soft);
  color: var(--np-muted);
}

.np-quiz-lock {
  padding: 26px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg-soft);
  text-align: center;
}

.np-quiz-lock h2 {
  margin: 0 0 10px;
  font-size: 20px;
}

.np-quiz-lock__ops,
.np-quiz-lock__try {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  align-items: center;
  margin-top: 14px;
}

/* --- 刷题页头部 --- */
.np-quiz-head {
  padding: 14px 0 8px;
}

.np-quiz-head__title {
  margin: 0 0 12px;
  font-size: 26px;
}

.np-quiz-tabs {
  display: flex;
  gap: 18px;
  border-bottom: 1px solid var(--np-line);
  margin-bottom: 14px;
}

.np-quiz-tab {
  padding: 8px 2px 10px;
  color: var(--np-muted);
  font-size: 15px;
}

.np-quiz-tab.is-active {
  box-shadow: inset 0 -2px 0 var(--np-primary);
  color: var(--np-primary);
  font-weight: 600;
}

.np-quiz-sub {
  margin: 0 0 14px;
  font-size: 20px;
}

.np-quiz-tip {
  color: var(--np-muted);
  font-size: 13px;
}

.np-quiz-tip a {
  color: var(--np-primary);
}

.npq-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 26px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.npq-stats li {
  display: flex;
  flex-direction: column;
}

.npq-stats strong {
  font-size: 22px;
  color: var(--np-text);
}

.npq-stats span {
  color: var(--np-muted);
  font-size: 12.5px;
}

/* --- 答题界面 --- */
.npq {
  margin: 10px 0 30px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
  overflow: hidden;
}

.npq-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 16px;
  background: var(--np-bg-soft);
  border-bottom: 1px solid var(--np-line);
}

.npq-bar__left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.npq-bar__bank {
  font-weight: 600;
  font-size: 15px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.npq-bar__mode {
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--np-primary-soft);
  color: var(--np-primary);
  font-size: 12px;
}

.npq-bar__right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.npq-bar__progress {
  color: var(--np-text-2);
  font-size: 13.5px;
}

.npq-bar__timer {
  padding: 3px 10px;
  border-radius: var(--np-radius-sm);
  background: var(--np-bg);
  border: 1px solid var(--np-line);
  font-variant-numeric: tabular-nums;
  font-size: 14px;
}

.npq-bar__timer.is-urgent {
  border-color: var(--np-accent);
  color: var(--np-accent);
}

.npq-progress {
  height: 3px;
  background: var(--np-line);
}

.npq-progress i {
  display: block;
  height: 100%;
  background: var(--np-primary);
  transition: width var(--np-transition);
}

.npq-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 240px;
  gap: 20px;
  padding: 18px;
}

.npq-item__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.npq-item__num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--np-primary);
  color: #fff;
  font-size: 13px;
}

.npq-item__type {
  padding: 2px 8px;
  border-radius: var(--np-radius-sm);
  background: var(--np-primary-soft);
  color: var(--np-primary);
  font-size: 12px;
}

.npq-item__type--multi { background: rgba(15, 138, 95, 0.12); color: #0f8a5f; }
.npq-item__type--judge { background: rgba(219, 166, 23, 0.14); color: #a37a08; }
.npq-item__type--fill { background: rgba(123, 79, 216, 0.12); color: #6a3fd0; }
.npq-item__type--essay { background: rgba(214, 54, 56, 0.12); color: #c6282a; }

.npq-item__diff {
  color: var(--np-muted);
  font-size: 12px;
}

.npq-item__diff--4,
.npq-item__diff--5 {
  color: var(--np-accent);
}

.npq-item__points {
  color: var(--np-muted);
  font-size: 12px;
}

.npq-item__title {
  margin-bottom: 16px;
  font-size: 16.5px;
  line-height: 1.75;
}

.npq-item__title p {
  margin: 0 0 8px;
}

/* 第 67 章 1.8.81 题库「看图答题」配图（纯末尾追加到刷题 section，不改 1~66 章） ------ */
.npq-item__image {
  position: relative;
  margin-bottom: 16px;
  border-radius: var(--np-radius-sm);
  overflow: hidden;
  background: var(--np-bg-soft);
  border: 1px solid var(--np-line);
}

.npq-item__image img {
  display: block;
  width: 100%;
  max-height: 420px;
  object-fit: contain;
}

.npq-item__look {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 2;
  padding: 3px 10px;
  font-size: 12px;
  line-height: 1.6;
  font-weight: 600;
  color: #fff;
  background: var(--np-primary);
  border-radius: 999px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.18);
}

.npq-options {
  margin: 0 0 16px;
  padding: 0;
  list-style: none;
}

.npq-option {
  margin-bottom: 9px;
}

.npq-option__label {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 11px 14px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  cursor: pointer;
  transition: border-color var(--np-transition), background var(--np-transition);
}

.npq-option__label:hover {
  border-color: var(--np-primary);
}

.npq-option input {
  margin: 4px 0 0;
}

.npq-option__key {
  flex: 0 0 auto;
  font-weight: 600;
  color: var(--np-text-2);
}

.npq-option__text {
  flex: 1 1 auto;
  line-height: 1.6;
}

.npq-option.is-right .npq-option__label {
  border-color: #0f8a5f;
  background: rgba(15, 138, 95, 0.08);
}

.npq-option.is-wrong .npq-option__label {
  border-color: var(--np-accent);
  background: rgba(214, 54, 56, 0.07);
}

.npq-input {
  width: 100%;
  padding: 11px 13px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg);
  color: var(--np-text);
  font-size: 15px;
}

.npq-input:focus {
  outline: none;
  border-color: var(--np-primary);
}

.npq-input--area {
  resize: vertical;
  line-height: 1.7;
}

.npq-feedback {
  margin: 0 0 14px;
  padding: 13px 15px;
  border-radius: var(--np-radius-sm);
  background: var(--np-bg-soft);
  font-size: 14px;
  line-height: 1.7;
}

.npq-feedback__flag {
  margin: 0 0 6px;
  font-weight: 600;
}

.npq-feedback__flag--ok { color: #0f8a5f; }
.npq-feedback__flag--no { color: var(--np-accent); }

.npq-feedback__right span,
.npq-feedback__ana span {
  display: inline-block;
  margin-right: 8px;
  padding: 1px 7px;
  border-radius: 999px;
  background: var(--np-primary-soft);
  color: var(--np-primary);
  font-size: 12px;
}

.npq-feedback__ana {
  margin-top: 6px;
  color: var(--np-text-2);
}

.npq-item__foot {
  display: flex;
  gap: 10px;
  padding-top: 4px;
}

.npq-btn {
  padding: 8px 18px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg);
  color: var(--np-text);
  font-size: 14px;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.npq-btn:hover {
  border-color: var(--np-primary);
  color: var(--np-primary);
}

.npq-btn--primary {
  border-color: var(--np-primary);
  background: var(--np-primary);
  color: #fff;
}

.npq-btn--primary:hover {
  background: var(--np-primary-dark, var(--np-primary));
  color: #fff;
}

.npq-btn--ghost {
  background: transparent;
}

.npq-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* --- 答题卡 --- */
.npq-side {
  min-width: 0;
}

.npq-card {
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  padding: 14px;
}

.npq-card__title {
  margin: 0 0 10px;
  font-size: 14px;
}

.npq-card__grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 7px;
}

.npq-card__num {
  padding: 7px 0;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg);
  color: var(--np-text-2);
  font-size: 13px;
  cursor: pointer;
  font-variant-numeric: tabular-nums;
}

.npq-card__num.is-done {
  border-color: var(--np-primary);
  background: var(--np-primary-soft);
  color: var(--np-primary);
}

.npq-card__num.is-current {
  box-shadow: 0 0 0 2px var(--np-primary-soft);
  font-weight: 600;
}

.npq-card__tip {
  margin: 10px 0 0;
  color: var(--np-muted);
  font-size: 12px;
}

/* --- 结果 --- */
.npq-result {
  border-top: 1px solid var(--np-line);
  padding: 18px;
}

.npq-result__card {
  padding: 22px;
  border-radius: var(--np-radius);
  background: var(--np-bg-soft);
  text-align: center;
}

.npq-result__title {
  margin: 0 0 10px;
  font-size: 18px;
}

.npq-result__score {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 4px;
}

.npq-result__score b {
  font-size: 46px;
  color: var(--np-primary);
  line-height: 1;
}

.npq-result__score span {
  color: var(--np-muted);
}

.npq-result__meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 26px;
  margin: 16px 0;
  padding: 0;
  list-style: none;
}

.npq-result__meta li {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.npq-result__meta span {
  color: var(--np-muted);
  font-size: 12.5px;
}

.npq-result__meta b {
  font-size: 17px;
}

.npq-result__flag {
  margin: 0 0 14px;
  font-size: 15px;
  font-weight: 600;
}

.npq-result__flag--pass { color: #0f8a5f; }
.npq-result__flag--fail { color: var(--np-accent); }

.npq-result__ops {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
}

.npq-result__tip {
  margin: 14px 0 0;
  color: var(--np-muted);
  font-size: 12.5px;
}

/* --- 错题本 --- */
.npq-wrong__sum {
  margin: 0 0 14px;
  color: var(--np-muted);
  font-size: 13px;
}

.npq-wrong__group {
  margin-bottom: 22px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  overflow: hidden;
}

.npq-wrong__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 16px;
  background: var(--np-bg-soft);
}

.npq-wrong__head h3 {
  margin: 0;
  font-size: 16px;
}

.npq-wrong__ops {
  display: flex;
  align-items: center;
  gap: 10px;
}

.npq-wrong__count {
  color: var(--np-muted);
  font-size: 13px;
}

.npq-wrong__list {
  margin: 0;
  padding: 0 16px;
  list-style: none;
}

.npq-wrong__item {
  padding: 14px 0;
  border-bottom: 1px dashed var(--np-line);
}

.npq-wrong__item:last-child {
  border-bottom: 0;
}

.npq-wrong__title {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 15.5px;
  line-height: 1.7;
}

.npq-wrong__answer {
  margin-top: 8px;
  color: var(--np-text-2);
  font-size: 14px;
  line-height: 1.7;
}

.npq-wrong__answer ul {
  margin: 0 0 6px;
  padding-left: 18px;
}

.npq-wrong__ana {
  margin: 4px 0 0;
}

.npq-wrong__foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 8px;
}

.npq-wrong__times {
  color: var(--np-muted);
  font-size: 12.5px;
}

/* --- 练习记录 --- */
.npq-records {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.npq-records th,
.npq-records td {
  padding: 11px 12px;
  border-bottom: 1px solid var(--np-line);
  text-align: left;
}

.npq-records th {
  background: var(--np-bg-soft);
  font-weight: 600;
}

.npq-records__sub {
  color: var(--np-muted);
  font-size: 12.5px;
}

.npq-pass {
  margin-left: 6px;
  color: #0f8a5f;
  font-size: 12px;
}

.npq-fail {
  margin-left: 6px;
  color: var(--np-accent);
  font-size: 12px;
}

@media (max-width: 900px) {
  .np-quiz-hero {
    grid-template-columns: minmax(0, 1fr);
  }

  .npq-body {
    grid-template-columns: minmax(0, 1fr);
  }

  .npq-card {
    display: none;
  }

  .npq-card.is-open {
    display: block;
  }

  .np-quiz-grid--3,
  .np-quiz-grid--4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  .np-quiz-grid--2,
  .np-quiz-grid--3,
  .np-quiz-grid--4 {
    grid-template-columns: minmax(0, 1fr);
  }

  .npq-bar {
    padding: 10px 12px;
  }

  .npq-bar__right {
    width: 100%;
    justify-content: space-between;
  }

  .npq-body {
    padding: 14px;
  }

  .npq-item__foot {
    position: sticky;
    bottom: 0;
    padding: 10px 0 4px;
    background: var(--np-bg);
  }

  .npq-item__foot .npq-btn {
    flex: 1 1 auto;
  }

  .npq-result__score b {
    font-size: 38px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .np-quiz-card,
  .npq-progress i {
    transition: none !important;
  }
}

/* ==========================================================================
   20. 课程 × 题库联动（1.8.23）
   ========================================================================== */

/* --- 返回课程 / 试刷提示 / 所属课程 --- */
.np-quiz-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 2px 0 18px;
  padding: 8px 14px;
  border: 1px solid var(--np-line);
  border-radius: 999px;
  background: var(--np-bg-soft);
  color: var(--np-text-2);
  font-size: 13px;
  text-decoration: none;
  transition: color var(--np-transition), border-color var(--np-transition);
}

.np-quiz-back:hover {
  color: var(--np-primary);
  border-color: var(--np-primary);
}

.np-quiz-trytip {
  margin: 0 0 16px;
  padding: 10px 14px;
  border-left: 3px solid #d97706;
  border-radius: var(--np-radius-sm);
  background: rgba(217, 119, 6, 0.09);
  color: var(--np-text-2);
  font-size: 13px;
}

.np-quiz-trytip--ok {
  border-left-color: #16a34a;
  background: rgba(22, 163, 74, 0.09);
}

.np-quiz-courses {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 14px 0 20px;
}

.np-quiz-courses__item {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 240px;
  padding: 10px 14px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg-soft);
  text-decoration: none;
  transition: border-color var(--np-transition), transform var(--np-transition);
}

.np-quiz-courses__item:hover {
  border-color: var(--np-primary);
  transform: translateY(-1px);
}

.np-quiz-courses__ico {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--np-primary-soft);
  color: var(--np-primary);
  flex: 0 0 auto;
}

.np-quiz-courses__body {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.np-quiz-courses__body i {
  color: var(--np-muted);
  font-size: 11px;
  font-style: normal;
}

.np-quiz-courses__body b {
  color: var(--np-text);
  font-size: 14px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.np-quiz-courses__go {
  margin-left: auto;
  color: var(--np-primary);
  font-size: 12px;
  white-space: nowrap;
}

/* --- 课程页：随堂测验 --- */
.np-course-quizzes__sum {
  margin-left: 10px;
  color: var(--np-muted);
  font-size: 13px;
  font-weight: 400;
}

.np-course-quizzes__progress {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 16px;
  color: var(--np-text-2);
  font-size: 13px;
}

.np-course-quizzes__ring {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 2px solid var(--np-primary);
  border-radius: 50%;
  color: var(--np-primary);
  font-size: 11px;
}

.np-course-quizzes__ring b {
  font-size: 14px;
}

.np-course-quizzes__pass,
.np-course-quizzes__todo {
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-style: normal;
}

.np-course-quizzes__pass {
  background: rgba(22, 163, 74, 0.12);
  color: #15803d;
}

.np-course-quizzes__todo {
  background: var(--np-bg-soft);
  color: var(--np-muted);
}

.np-course-quizzes__hint {
  margin: 0 0 16px;
  padding: 10px 14px;
  border-radius: var(--np-radius-sm);
  background: var(--np-primary-soft);
  color: var(--np-text-2);
  font-size: 13px;
}

.np-course-quizzes__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
  gap: 14px;
}

.np-course-quiz {
  display: flex;
  flex-direction: column;
  padding: 16px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
}

.np-course-quiz.is-final {
  border-color: rgba(217, 119, 6, 0.5);
  background: linear-gradient(180deg, rgba(217, 119, 6, 0.06), transparent 60%);
}

.np-course-quiz.is-passed {
  border-color: rgba(22, 163, 74, 0.45);
}

.np-course-quiz__head {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.np-course-quiz__ico {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 9px;
  background: var(--np-primary-soft);
  color: var(--np-primary);
  flex: 0 0 auto;
}

.np-course-quiz__title {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.np-course-quiz__title b {
  color: var(--np-text);
  font-size: 15px;
  line-height: 1.4;
}

.np-course-quiz__tag {
  align-self: flex-start;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(217, 119, 6, 0.14);
  color: #b45309;
  font-size: 11px;
  font-style: normal;
}

.np-course-quiz__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 14px;
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
  color: var(--np-muted);
  font-size: 12px;
}

.np-course-quiz__meta strong {
  color: var(--np-text);
  font-size: 14px;
}

.np-course-quiz__best {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 12px 0 0;
  color: var(--np-text-2);
  font-size: 12px;
}

.np-course-quiz__best b {
  color: var(--np-primary);
  font-size: 17px;
}

.np-course-quiz__best em {
  color: var(--np-muted);
  font-style: normal;
}

.np-course-quiz__best--none {
  color: var(--np-muted);
}

.np-course-quiz__ok {
  color: #15803d !important;
}

.np-course-quiz__ops {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: auto;
  padding-top: 14px;
}

.np-course-quiz__more {
  margin-left: auto;
  color: var(--np-muted);
  font-size: 12px;
}

/* --- 课程目录里的本章测验 --- */
.np-course-chapter__quiz {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  margin-top: 6px;
  border: 1px dashed var(--np-primary);
  border-radius: var(--np-radius-sm);
  background: var(--np-primary-soft);
  color: var(--np-text-2);
  font-size: 13px;
  text-decoration: none;
  transition: background var(--np-transition);
}

.np-course-chapter__quiz:hover {
  background: rgba(34, 113, 177, 0.16);
}

.np-course-chapter__quiz.is-passed {
  border-color: #16a34a;
  background: rgba(22, 163, 74, 0.09);
}

.np-course-chapter__quiz-ico {
  display: grid;
  place-items: center;
  color: var(--np-primary);
  flex: 0 0 auto;
}

.np-course-chapter__quiz.is-passed .np-course-chapter__quiz-ico {
  color: #15803d;
}

.np-course-chapter__quiz-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--np-text);
}

.np-course-chapter__quiz-meta {
  color: var(--np-muted);
  font-size: 12px;
  white-space: nowrap;
}

.np-course-chapter__quiz-go {
  margin-left: auto;
  color: var(--np-primary);
  font-size: 12px;
  white-space: nowrap;
}

/* --- 后台：题库选择 --- */
.np-course-quizpick,
.np-quiz-coursepick {
  display: grid;
  gap: 6px;
  max-height: 210px;
  overflow-y: auto;
  padding: 10px;
  margin: 10px 0;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg-soft);
}

.np-course-quizpick__item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 2px;
  font-size: 13px;
}

.np-course-quizpick__item span {
  flex: 1;
}

.np-course-quizpick__item i {
  color: var(--np-muted);
  font-style: normal;
  font-size: 12px;
}

.np-quiz-coursepick label {
  display: block;
  font-size: 13px;
}

.np-course-ch__quiz {
  margin: 6px 0 10px;
  padding-left: 22px;
  font-size: 12px;
}

.np-course-ch__quiz select {
  max-width: 260px;
}

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

  .np-course-chapter__quiz {
    flex-wrap: wrap;
  }

  .np-course-chapter__quiz-go {
    margin-left: 0;
  }
}

/* ==========================================================================
   21. 订单交付：地址表单 / 订单详情 / 卡密 / 物流 / 后台发货（1.8.24）
   ========================================================================== */

/* --- 收货地址表单（购物车、商品详情页、订单页共用） --- */
.np-addr {
  margin: 16px 0;
  padding: 14px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg-soft);
}

.np-addr__title {
  display: flex;
  align-items: center;
  gap: 7px;
  margin: 0 0 12px;
  font-size: 14px;
  font-weight: 600;
  color: var(--np-text);
}

.np-addr__req {
  margin-left: auto;
  font-size: 11px;
  font-weight: 400;
  color: var(--np-accent);
}

.np-addr__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px;
}

.np-addr__field {
  display: block;
  min-width: 0;
}

.np-addr__field--wide {
  grid-column: 1 / -1;
}

.np-addr__field > span {
  display: block;
  margin-bottom: 5px;
  font-size: 12px;
  color: var(--np-text-2);
}

.np-addr__field i {
  color: var(--np-accent);
  font-style: normal;
}

.np-addr__field input {
  width: 100%;
  height: 36px;
  padding: 0 10px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg);
  color: var(--np-text);
  font-size: 13px;
  box-sizing: border-box;
}

.np-addr__field input:focus {
  outline: none;
  border-color: var(--np-primary);
  box-shadow: 0 0 0 3px var(--np-primary-soft);
}

.np-addr__tip {
  margin: 10px 0 0;
  font-size: 12px;
  color: var(--np-accent);
}

/* --- 订单详情页 --- */
.np-order {
  max-width: 1080px;
  margin: 0 auto;
  padding: 24px 0 48px;
}

.np-order-empty {
  max-width: 520px;
  margin: 60px auto;
  padding: 40px 24px;
  text-align: center;
  color: var(--np-muted);
}

.np-order-empty h1 {
  margin: 14px 0 8px;
  font-size: 22px;
  color: var(--np-text);
}

.np-order-empty p {
  margin: 0 0 20px;
  font-size: 14px;
}

.np-order__hero {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 22px 24px;
  border: 1px solid var(--np-line);
  border-left: 4px solid var(--np-primary);
  border-radius: var(--np-radius);
  background: var(--np-bg);
  box-shadow: var(--np-shadow);
}

.np-order__hero.is-paid {
  border-left-color: #16a34a;
}

.np-order__hero.is-just {
  animation: npOrderIn 500ms ease-out both;
}

@keyframes npOrderIn {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: none; }
}

.np-order__hero-icon {
  display: grid;
  place-items: center;
  flex: 0 0 52px;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: #16a34a1a;
  color: #16a34a;
}

.np-order__hero.is-pending .np-order__hero-icon {
  background: var(--np-primary-soft);
  color: var(--np-primary);
}

.np-order__hero-text {
  flex: 1 1 auto;
  min-width: 0;
}

.np-order__hero-text h1 {
  margin: 0 0 5px;
  font-size: 22px;
  color: var(--np-text);
}

.np-order__hero-text p {
  margin: 0;
  font-size: 13px;
  line-height: 1.6;
  color: var(--np-text-2);
}

.np-order__hero-meta {
  flex: 0 0 auto;
  text-align: right;
  font-size: 12px;
  color: var(--np-muted);
}

.np-order__hero-meta span {
  display: block;
  margin-bottom: 6px;
}

.np-order__hero-meta code {
  margin-left: 6px;
  color: var(--np-text-2);
  font-size: 11px;
}

.np-order__hero-meta strong {
  font-size: 22px;
  color: var(--np-accent);
}

/* 进度条 */
.np-order__steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  margin: 20px 0;
  padding: 16px 10px;
  list-style: none;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
}

.np-order__step {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  text-align: center;
  font-size: 12px;
  color: var(--np-muted);
}

.np-order__step:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 13px;
  left: 60%;
  width: 80%;
  height: 2px;
  background: var(--np-line);
}

.np-order__step.is-done:not(:last-child)::after {
  background: #16a34a;
}

.np-order__step-dot {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 2px solid var(--np-line);
  background: var(--np-bg);
  font-size: 12px;
  font-weight: 600;
}

.np-order__step.is-done .np-order__step-dot {
  border-color: #16a34a;
  background: #16a34a;
  color: #fff;
}

.np-order__step.is-current .np-order__step-dot {
  border-color: var(--np-primary);
  color: var(--np-primary);
}

.np-order__step-label {
  font-weight: 600;
  color: var(--np-text-2);
}

.np-order__step.is-done .np-order__step-label {
  color: var(--np-text);
}

.np-order__step time {
  font-size: 11px;
}

/* 两栏主体 */
.np-order__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 20px;
  align-items: start;
}

.np-order__main {
  display: grid;
  gap: 20px;
  min-width: 0;
}

.np-order__side {
  display: grid;
  gap: 16px;
}

.np-order__card {
  padding: 20px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
  box-shadow: var(--np-shadow);
}

.np-order__card--side {
  padding: 16px;
}

.np-order__card-title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--np-line);
  font-size: 16px;
  color: var(--np-text);
}

.np-order__card-title svg {
  color: var(--np-primary);
}

.np-order__badge {
  margin-left: auto;
  padding: 3px 9px;
  border-radius: 20px;
  background: var(--np-primary-soft);
  color: var(--np-primary);
  font-size: 11px;
  font-weight: 600;
}

.np-order__badge--delivered,
.np-order__badge--completed {
  background: #16a34a1a;
  color: #16a34a;
}

.np-order__badge--pending {
  background: #d977061a;
  color: #b45309;
}

.np-order__hint {
  margin: 0 0 12px;
  font-size: 13px;
  line-height: 1.7;
  color: var(--np-text-2);
}

/* 交付物 */
.np-deliver {
  padding: 14px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg-soft);
}

.np-deliver + .np-deliver {
  margin-top: 12px;
}

.np-deliver__head {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 10px;
  font-size: 14px;
}

.np-deliver__head strong {
  color: var(--np-text);
}

.np-deliver__head > span {
  font-size: 12px;
  color: var(--np-muted);
}

.np-deliver__tag {
  margin-left: auto;
  padding: 2px 8px;
  border-radius: 20px;
  background: #16a34a1a;
  color: #16a34a;
  font-size: 11px;
  font-style: normal;
}

.np-deliver__tag--wait {
  background: #d977061a;
  color: #b45309;
}

.np-deliver__cards {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.np-deliver__cards li {
  padding: 10px 12px;
  border: 1px dashed var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg);
}

.np-deliver__kv {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 30px;
  font-size: 13px;
}

.np-deliver__kv > span {
  flex: 0 0 38px;
  color: var(--np-muted);
  font-size: 12px;
}

.np-deliver__kv code {
  flex: 1 1 auto;
  min-width: 0;
  color: var(--np-text);
  font-size: 13px;
  word-break: break-all;
  user-select: all;
}

.np-deliver__copy {
  flex: 0 0 auto;
  padding: 3px 9px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg);
  color: var(--np-primary);
  font-size: 11px;
  cursor: pointer;
  transition: var(--np-transition);
}

.np-deliver__copy:hover,
.np-deliver__copy.is-copied {
  border-color: var(--np-primary);
  background: var(--np-primary-soft);
}

.np-deliver__content {
  padding: 12px 14px;
  border-radius: var(--np-radius-sm);
  background: var(--np-bg);
  font-size: 13px;
  line-height: 1.85;
  color: var(--np-text-2);
  white-space: pre-wrap;
  word-break: break-word;
}

.np-deliver__download {
  margin-top: 10px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.np-deliver__text,
.np-deliver__tip {
  margin: 8px 0 0;
  font-size: 12px;
  line-height: 1.7;
  color: var(--np-text-2);
}

.np-deliver__wait {
  margin: 8px 0 0;
  font-size: 12px;
  color: #b45309;
}

.np-deliver__warn {
  margin: 10px 0 0;
  padding: 8px 10px;
  border-radius: var(--np-radius-sm);
  background: #d977061a;
  color: #b45309;
  font-size: 12px;
}

.np-deliver__ship {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 10px;
  padding: 10px 12px;
  border-radius: var(--np-radius-sm);
  background: var(--np-bg);
  font-size: 12px;
}

.np-deliver__ship span {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--np-muted);
}

.np-deliver__ship b,
.np-deliver__ship code {
  color: var(--np-text);
}

.np-order__receive {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 16px;
  padding: 14px;
  border-radius: var(--np-radius-sm);
  background: var(--np-primary-soft);
}

.np-order__receive p {
  flex: 1 1 auto;
  margin: 0;
  font-size: 13px;
  color: var(--np-text-2);
}

.np-order__done-note {
  margin: 14px 0 0;
  font-size: 13px;
  color: #16a34a;
}

/* 明细表 */
.np-table--order-items tfoot td {
  border-top: 1px solid var(--np-line);
  padding-top: 10px;
  font-size: 13px;
  color: var(--np-text-2);
}

.np-table--order-items tfoot td:last-child,
.np-table--order-items td:last-child {
  text-align: right;
}

.np-table--order-items small {
  display: block;
  margin-top: 3px;
  font-size: 11px;
  color: var(--np-muted);
}

.np-order__total td {
  font-weight: 600;
  color: var(--np-text) !important;
}

.np-order__total b {
  font-size: 17px;
  color: var(--np-accent);
}

/* 侧栏 */
.np-order__addr p {
  margin: 0 0 6px;
  font-size: 13px;
  line-height: 1.6;
  color: var(--np-text-2);
}

.np-order__addr strong {
  font-size: 15px;
  color: var(--np-text);
}

.np-order__addr span {
  margin-left: 8px;
  color: var(--np-muted);
}

.np-order__addr-note {
  padding-top: 6px;
  border-top: 1px dashed var(--np-line);
  color: var(--np-muted) !important;
  font-size: 12px !important;
}

.np-order__addr-form {
  margin-top: 12px;
}

.np-order__addr-form[hidden],
.np-orders-ship[hidden] {
  display: none !important;
}

.np-order__meta {
  margin: 0;
  display: grid;
  gap: 9px;
  font-size: 12px;
}

.np-order__meta > div {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}

.np-order__meta dt {
  color: var(--np-muted);
}

.np-order__meta dd {
  margin: 0;
  text-align: right;
  color: var(--np-text-2);
}

.np-order__meta code {
  font-size: 11px;
  word-break: break-all;
}

.np-order__ops {
  display: grid;
  gap: 10px;
}

.np-order__msg {
  margin: 0;
  font-size: 12px;
  line-height: 1.6;
}

.np-order__msg.is-ok { color: #16a34a; }
.np-order__msg.is-err { color: var(--np-accent); }
.np-order__msg--global { text-align: center; }

/* 我的订单：交付状态小标 */
.np-order-flag {
  display: inline-block;
  margin-top: 4px;
  padding: 1px 7px;
  border-radius: 20px;
  background: var(--np-primary-soft);
  color: var(--np-primary);
  font-size: 11px;
  white-space: nowrap;
}

.np-order-flag--pending { background: #d977061a; color: #b45309; }
.np-order-flag--delivered,
.np-order-flag--completed { background: #16a34a1a; color: #16a34a; }

/* 后台发货面板 */
.np-orders-ship {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(15, 20, 25, 0.55);
}

.np-orders-ship__box {
  width: min(560px, 100%);
  max-height: 90vh;
  overflow: auto;
  padding: 22px 24px;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
}

.np-orders-ship__box h2 {
  margin: 0 0 8px;
  font-size: 18px;
}

.np-orders-ship__box .form-table th {
  width: 130px;
}

.np-orders-ship__box .submit {
  margin-bottom: 0;
}

/* 响应式 */
@media (max-width: 980px) {
  .np-order__grid {
    grid-template-columns: 1fr;
  }

  .np-order__side {
    order: -1;
  }
}

@media (max-width: 640px) {
  .np-order {
    padding: 16px 0 36px;
  }

  .np-order__hero {
    flex-wrap: wrap;
    padding: 16px;
  }

  .np-order__hero-text {
    flex: 1 1 calc(100% - 70px);
  }

  .np-order__hero-meta {
    flex: 1 1 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    text-align: left;
    padding-top: 10px;
    border-top: 1px solid var(--np-line);
  }

  .np-order__hero-meta span { margin-bottom: 0; }

  .np-order__steps {
    padding: 12px 4px;
  }

  .np-order__step-label { font-size: 11px; }
  .np-order__step time { display: none; }

  .np-order__card { padding: 14px; }
  .np-order__card--side { padding: 14px; }

  .np-deliver__head { font-size: 13px; }
  .np-deliver__tag { margin-left: 0; }

  .np-deliver__kv { flex-wrap: wrap; }
  .np-deliver__kv code { flex-basis: 100%; order: 3; }
  .np-deliver__kv .np-deliver__copy { margin-left: auto; }

  .np-addr__grid { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  .np-order__hero.is-just { animation: none; }
}

/* ==========================================================================
   22. 卡密中心与站内私信（1.8.25）
   ========================================================================== */

/* hidden 属性在这些组件里必须真的藏起来：徽标、空态、表单都靠它切换。 */
.npm [hidden],
.npm-toggle__badge[hidden],
.np-redeem [hidden],
.np-account__quick [hidden] { display: none !important; }

/* --- 头部私信入口 --- */
.npm-toggle {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  color: var(--np-text-2);
  border-radius: var(--np-radius-sm);
  transition: background var(--np-transition), color var(--np-transition);
}
.npm-toggle:hover { background: var(--np-bg-soft); color: var(--np-primary); }
.npm-toggle__badge {
  position: absolute;
  top: -2px;
  right: -4px;
  min-width: 17px;
  height: 17px;
  padding: 0 4px;
  box-sizing: border-box;
  border-radius: 9px;
  background: var(--np-accent);
  color: #fff;
  font-size: 10px;
  font-style: normal;
  font-weight: 700;
  line-height: 17px;
  text-align: center;
}
.np-drawer__quick {
  display: flex;
  gap: 8px;
  margin: 10px 0 4px;
  flex-wrap: wrap;
}
.np-drawer__quick a {
  position: relative;
  padding: 6px 12px;
  border: 1px solid var(--np-line);
  border-radius: 999px;
  font-size: 12px;
  color: var(--np-text-2);
}
.np-drawer__quick a:hover { border-color: var(--np-primary); color: var(--np-primary); }
.np-drawer__quick .npm-toggle__badge { top: -6px; right: -6px; }

.np-account__quick { list-style: none; margin: 0; padding: 0; }
.np-account__quick li + li { border-top: 1px solid var(--np-line); }
.np-account__quick a {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 10px 2px;
  color: var(--np-text);
}
.np-account__quick a:hover strong { color: var(--np-primary); }
.np-account__quick strong { font-size: 14px; }
.np-account__quick span { font-size: 12px; color: var(--np-muted); }
.np-account__quick .npm-toggle__badge { position: absolute; top: 12px; right: 4px; }

/* --- 卡密兑换页 --- */
.np-redeem { max-width: 980px; margin: 32px auto 56px; }
.np-redeem__hero {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px 22px;
  margin-bottom: 20px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
  box-shadow: var(--np-shadow);
}
.np-redeem__hero-icon {
  flex: 0 0 52px;
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: var(--np-primary-soft);
  color: var(--np-primary);
}
.np-redeem__hero h1 { margin: 0 0 4px; font-size: 21px; }
.np-redeem__hero p { margin: 0; font-size: 13px; color: var(--np-muted); line-height: 1.6; }
.np-redeem__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.np-redeem__panel {
  padding: 20px;
  margin-bottom: 18px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
}
.np-redeem__grid .np-redeem__panel { margin-bottom: 0; }
.np-redeem__title { margin: 0 0 14px; font-size: 16px; }
.np-redeem__form .np-form-row { margin-bottom: 12px; }
.np-redeem__form .np-form-row label { display: block; margin-bottom: 5px; font-size: 13px; font-weight: 600; }
.np-redeem__form input {
  width: 100%;
  box-sizing: border-box;
  padding: 9px 11px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg);
  color: var(--np-text);
  font-size: 14px;
}
.np-redeem__result {
  margin-top: 14px;
  padding: 10px 12px;
  border-radius: var(--np-radius-sm);
  font-size: 13px;
  line-height: 1.6;
}
.np-redeem__result.is-ok { background: rgba(29, 122, 61, 0.1); color: #1d7a3d; }
.np-redeem__result.is-err { background: rgba(214, 54, 56, 0.1); color: var(--np-accent); }
.np-redeem__result.is-info { background: var(--np-bg-soft); color: var(--np-text-2); }
.np-redeem__hint { margin: 12px 0 0; font-size: 12px; line-height: 1.7; color: var(--np-muted); }
.np-redeem__who { margin: 10px 0 0; font-size: 12px; color: var(--np-muted); }
.np-redeem__empty { margin: 6px 0; font-size: 13px; color: var(--np-muted); }
.np-redeem__card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 0;
  border-bottom: 1px dashed var(--np-line);
}
.np-redeem__card:last-child { border-bottom: 0; }
.np-redeem__card.is-done { opacity: 0.6; }
.np-redeem__card-main { min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.np-redeem__card-main strong { font-size: 13px; }
.np-redeem__card-main code { font-size: 12px; color: var(--np-primary); word-break: break-all; }
.np-redeem__card-main span { font-size: 12px; color: var(--np-muted); }
.np-redeem__tag {
  flex: 0 0 auto;
  padding: 3px 8px;
  border-radius: 999px;
  background: var(--np-bg-soft);
  font-size: 11px;
  font-style: normal;
  color: var(--np-muted);
}
.np-redeem__logs { list-style: none; margin: 0; padding: 0; }
.np-redeem__logs li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 0;
  border-bottom: 1px dashed var(--np-line);
  font-size: 12px;
}
.np-redeem__logs li:last-child { border-bottom: 0; }
.np-redeem__logs code { color: var(--np-primary); }
.np-redeem__logs span { flex: 1; color: var(--np-text-2); }
.np-redeem__logs time { color: var(--np-muted); }
.np-redeem__foot { display: flex; gap: 18px; margin-top: 16px; font-size: 13px; }
.np-redeem__login { text-align: center; }
.np-redeem__login h1, .np-redeem__login h2 { margin-top: 0; }
.np-deliver__redeem {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 10px;
  padding: 10px 12px;
  border-radius: var(--np-radius-sm);
  background: var(--np-primary-soft);
  font-size: 13px;
  color: var(--np-primary);
}

/* --- 后台卡密 / 私信管理 --- */
.np-admin-cards__stats { display: flex; flex-wrap: wrap; gap: 12px; margin: 18px 0; }
.np-admin-cards__stat {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 104px;
  padding: 12px 16px;
  border: 1px solid #dcdcde;
  border-radius: 6px;
  background: #fff;
}
.np-admin-cards__stat strong { font-size: 22px; line-height: 1.2; }
.np-admin-cards__stat span { font-size: 12px; color: #646970; }
.np-admin-cards__cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 16px; }
.np-admin-cards__panel {
  padding: 14px 18px 18px;
  border: 1px solid #dcdcde;
  border-radius: 6px;
  background: #fff;
}
.np-admin-cards__panel h2 { margin-top: 0; font-size: 15px; }
.np-admin-cards__filter { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0; align-items: center; }

/* --- 私信页 --- */
.npm {
  display: grid;
  grid-template-columns: 300px 1fr;
  height: min(72vh, 660px);
  min-height: 460px;
  margin: 30px 0 16px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
  box-shadow: var(--np-shadow);
  overflow: hidden;
}
.npm__side { display: flex; flex-direction: column; border-right: 1px solid var(--np-line); min-height: 0; }
.npm__side-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid var(--np-line);
}
.npm__side-head h1 { margin: 0; font-size: 16px; }
.npm__new {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 5px 10px;
  border: 1px solid var(--np-line);
  border-radius: 999px;
  background: var(--np-bg);
  color: var(--np-primary);
  font-size: 12px;
  cursor: pointer;
}
.npm__new:hover { border-color: var(--np-primary); }
.npm__search { padding: 12px 14px; border-bottom: 1px solid var(--np-line); }
.npm__search input {
  width: 100%;
  box-sizing: border-box;
  padding: 7px 10px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg);
  color: var(--np-text);
  font-size: 13px;
}
.npm__search-list { max-height: 180px; overflow-y: auto; margin-top: 8px; }
.npm__search-hint { margin: 8px 0 0; font-size: 11px; color: var(--np-muted); }
.npm__none { padding: 16px 14px; margin: 0; font-size: 12px; color: var(--np-muted); }
.npm__user {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  padding: 7px 8px;
  border: 0;
  border-radius: var(--np-radius-sm);
  background: transparent;
  color: var(--np-text);
  font-size: 13px;
  text-align: left;
  cursor: pointer;
}
.npm__user:hover { background: var(--np-bg-soft); }
.npm__user img { width: 28px; height: 28px; border-radius: 50%; }
.npm__threads { flex: 1; overflow-y: auto; min-height: 0; }
.npm__thread {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 11px 14px;
  border: 0;
  border-bottom: 1px solid var(--np-line);
  background: transparent;
  text-align: left;
  cursor: pointer;
}
.npm__thread:hover { background: var(--np-bg-soft); }
.npm__thread.is-active { background: var(--np-primary-soft); }
.npm__thread-avatar { flex: 0 0 38px; width: 38px; height: 38px; border-radius: 50%; }
.npm__thread-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.npm__thread-name { font-size: 13px; color: var(--np-text); }
.npm__thread-last { font-size: 12px; color: var(--np-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.npm__thread.is-unread .npm__thread-name { font-weight: 700; }
.npm__thread-meta { flex: 0 0 auto; display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.npm__thread-meta time { font-size: 10px; color: var(--np-muted); }
.npm__thread-badge {
  min-width: 17px;
  height: 17px;
  padding: 0 4px;
  box-sizing: border-box;
  border-radius: 9px;
  background: var(--np-accent);
  color: #fff;
  font-size: 10px;
  font-style: normal;
  font-weight: 700;
  line-height: 17px;
  text-align: center;
}
.npm__chat { display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.npm__chat-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 16px;
  border-bottom: 1px solid var(--np-line);
}
.npm__back { display: none; border: 0; background: transparent; color: var(--np-text-2); cursor: pointer; }
.npm__peer-avatar { width: 34px; height: 34px; border-radius: 50%; }
.npm__peer { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.npm__peer strong { font-size: 14px; }
.npm__peer span { font-size: 11px; color: var(--np-muted); }
.npm__hide { border: 0; background: transparent; color: var(--np-muted); font-size: 12px; cursor: pointer; }
.npm__hide:hover { color: var(--np-accent); }
.npm__messages {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 18px 20px;
  background: var(--np-bg-soft);
}
.npm__msg { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; margin-bottom: 14px; }
.npm__msg.is-mine { align-items: flex-end; }
.npm__bubble {
  max-width: min(76%, 560px);
  padding: 9px 13px;
  border: 1px solid var(--np-line);
  border-radius: 12px 12px 12px 3px;
  background: var(--np-bg);
  font-size: 13px;
  line-height: 1.65;
  white-space: pre-wrap;
  word-break: break-word;
}
.npm__msg.is-mine .npm__bubble {
  border-color: transparent;
  border-radius: 12px 12px 3px 12px;
  background: var(--np-primary);
  color: #fff;
}
.npm__msg-time { font-size: 10px; color: var(--np-muted); }
.npm__empty {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: var(--np-muted);
  text-align: center;
  padding: 20px;
}
.npm__empty h2 { margin: 4px 0 0; font-size: 16px; color: var(--np-text-2); }
.npm__empty p { margin: 0; font-size: 12px; }
.npm__composer { padding: 12px 16px; border-top: 1px solid var(--np-line); }
.npm__composer textarea {
  width: 100%;
  box-sizing: border-box;
  padding: 9px 11px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg);
  color: var(--np-text);
  font-size: 13px;
  resize: vertical;
}
.npm__composer-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 8px; }
.npm__tip { flex: 1; font-size: 12px; color: var(--np-accent); }
.npm__foot { display: flex; gap: 18px; font-size: 13px; color: var(--np-muted); }

@media (max-width: 760px) {
  .np-redeem__grid { grid-template-columns: 1fr; }
  .npm { grid-template-columns: 1fr; height: min(78vh, 620px); }
  .npm:not(.is-chat) .npm__chat { display: none; }
  .npm.is-chat .npm__side { display: none; }
  .npm__back { display: inline-flex; }
  .np-redeem__hero { padding: 16px; }
  .np-redeem__hero h1 { font-size: 18px; }
  .np-deliver__redeem { flex-direction: column; align-items: flex-start; }
}

/* ==========================================================================
   23. QQ 快捷登录（1.8.26，图标于 1.8.27 改用官方在线图标）
   ========================================================================== */
.np-auth__social { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--np-line); text-align: center; }
.np-auth__social-label { display: flex; align-items: center; justify-content: center; gap: 10px; margin-bottom: 14px; font-size: 12px; color: var(--np-muted); }
.np-auth__social-label::before,
.np-auth__social-label::after { content: ''; flex: 1; height: 1px; background: var(--np-line); }

.np-auth__qq {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%; min-height: 42px; padding: 0 16px;
  border: 1px solid #12b7f5; border-radius: var(--np-radius-sm);
  background: #12b7f5; color: #fff;
  font-size: 14px; font-weight: 600; text-decoration: none;
  transition: var(--np-transition);
}
.np-auth__qq:hover { background: #0aa3dd; border-color: #0aa3dd; color: #fff; }
.np-auth__qq svg,
.np-auth__qq img { flex: none; }
/* 官方 QQ 在线图标（透明底彩色企鹅）；与内置兜底 SVG 同尺寸，切换时不跳动 */
.np-auth__qq .np-auth__qq-logo { display: block; width: 22px; height: 22px; object-fit: contain; }
.np-auth__qq--inline { width: auto; min-height: 38px; padding: 0 18px; }
.np-auth__social .np-form-hint { margin: 10px 0 0; font-size: 12px; line-height: 1.6; color: var(--np-muted); }

.np-account__qq .np-auth__form { margin-top: 12px; }
.np-qq-unbind { margin-top: 12px; }

/* 主题设置里的配置说明块 */
.np-qq-tip { max-width: 680px; }
.np-qq-tip p { margin: 0 0 8px; font-size: 13px; line-height: 1.7; color: var(--np-text-2); }
.np-qq-tip__row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.np-qq-tip__row label { font-weight: 600; }
.np-qq-tip__row input { font-family: monospace; font-size: 12px; }
.np-qq-tip__hint { color: var(--np-muted) !important; }
.np-qq-tip__warn { color: var(--np-accent) !important; }
.np-qq-tip__ok { color: #1d7a3d !important; }

@media (max-width: 760px) {
  .np-auth__qq--inline { width: 100%; }
}

/* --- 24.1 微信扫码登录（未认证公众号 / 订阅号）-------------------------------- */
.np-auth__wx {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%; min-height: 42px; padding: 0 16px;
  border: 1px solid #07c160; border-radius: var(--np-radius-sm);
  background: #07c160; color: #fff;
  font-size: 14px; font-weight: 600; text-decoration: none; cursor: pointer;
  transition: var(--np-transition);
}
.np-auth__wx:hover { background: #06ad56; border-color: #06ad56; color: #fff; }
.np-auth__wx svg { flex: none; }
.np-auth__wx--inline { width: auto; min-height: 38px; padding: 0 18px; }

/* 扫码弹窗：遮罩 + 居中卡片（z-index 高于登录弹窗与收银台） */
.np-wx-pop { position: fixed; inset: 0; z-index: 9999; display: flex; align-items: center; justify-content: center; }
.np-wx-pop[hidden] { display: none; }
/* .np-btn/.np-btn--block 的 display 会覆盖 UA 的 [hidden]{display:none}，
   导致「刷新」等临时隐藏的按钮仍然占位；在弹窗作用域内显式复位。 */
.np-wx-pop [hidden] { display: none !important; }
.np-wx-pop__mask { position: absolute; inset: 0; background: rgba(16, 24, 40, .55); }
.np-wx-pop__panel {
  position: relative; width: min(340px, calc(100vw - 32px)); padding: 24px 22px 22px;
  background: var(--np-bg, #fff); border-radius: var(--np-radius, 12px);
  box-shadow: var(--np-shadow, 0 12px 40px rgba(16, 24, 40, .18)); text-align: center;
}
.np-wx-pop__close {
  position: absolute; top: 10px; right: 10px; width: 30px; height: 30px;
  display: flex; align-items: center; justify-content: center;
  border: 0; border-radius: 8px; background: transparent; color: var(--np-muted, #7a838f); cursor: pointer;
}
.np-wx-pop__close:hover { background: var(--np-bg-soft, #f5f6f8); }
.np-wx-pop__badge {
  display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px;
  border-radius: 12px; background: rgba(7, 193, 96, .12); color: #07c160; margin-bottom: 10px;
}
.np-wx-pop__title { margin: 0 0 6px; font-size: 17px; font-weight: 700; color: var(--np-text, #1f2733); }
.np-wx-pop__tip { margin: 0 0 16px; font-size: 12.5px; line-height: 1.6; color: var(--np-muted, #7a838f); }
.np-wx-pop__qr {
  width: 180px; height: 180px; margin: 0 auto 14px; padding: 8px;
  border: 1px solid var(--np-line, #e6e9ee); border-radius: 10px; background: #fff;
}
.np-wx-pop__qr-img { width: 100%; height: 100%; object-fit: contain; display: block; }
.np-wx-pop__code {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
  font-size: 28px; font-weight: 800; letter-spacing: 6px; color: #07c160; margin: 0 0 8px;
}
.np-wx-pop__hint { margin: 0 0 4px; font-size: 13px; color: var(--np-text-2, #4a5563); }
.np-wx-pop__hint.is-error { color: var(--np-accent, #d83434); }
.np-wx-pop__refresh { margin-top: 8px; }

/* --- 24.2 微信强制绑定 QQ 邮箱（用户中心置顶卡片）-------------------------- */
.np-wx-email {
  margin: 0 0 22px;
  padding: 20px 22px;
  border: 1px solid rgba(7, 193, 96, .34);
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(7, 193, 96, .07), rgba(7, 193, 96, .02));
}
.np-wx-email__head { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 14px; }
.np-wx-email__head > svg { flex: 0 0 auto; margin-top: 2px; color: #07a854; }
.np-wx-email__head strong { display: block; font-size: 16px; font-weight: 700; color: var(--np-text, #1f2733); }
.np-wx-email__head p { margin: 6px 0 0; font-size: 13px; line-height: 1.7; color: var(--np-muted, #7a838f); }
.np-wx-email__form { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px 12px; margin: 0 0 4px; }
.np-wx-email__form .np-form-row { flex: 1 1 260px; margin: 0; }
.np-wx-email__form .np-form-hint { flex: 1 1 100%; margin: 0; font-size: 12px; }
.np-wx-email__form--code { padding-top: 14px; border-top: 1px dashed rgba(7, 193, 96, .32); }
.np-wx-email__form .np-btn[disabled] { opacity: .6; cursor: not-allowed; }
.np-wx-email__form #np-wx-email-code { max-width: 180px; letter-spacing: 4px; font-size: 18px; text-align: center; }
body.np-dark .np-wx-email {
  border-color: rgba(7, 193, 96, .28);
  background: linear-gradient(180deg, rgba(7, 193, 96, .10), rgba(7, 193, 96, .03));
}
@media (max-width: 600px) {
  .np-wx-email { padding: 16px; }
  .np-wx-email__form .np-form-row { flex-basis: 100%; }
}


/* ==========================================================================
   24. 商城购买登录要求与登录弹窗（1.8.28）
   ========================================================================== */
body.np-login-open { overflow: hidden; }

/* z-index 高于收银台：服务端返回「需要登录」时登录框要盖在收银台上面 */
.np-login {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.np-login[hidden] { display: none; }
.np-login__mask {
  position: absolute;
  inset: 0;
  background: rgba(12, 17, 24, 0.58);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  animation: np-ck-fade 0.2s ease both;
}
.np-login__panel {
  position: relative;
  width: min(400px, 100%);
  max-height: min(90vh, 720px);
  overflow-y: auto;
  padding: 26px 26px 22px;
  border-radius: 16px;
  background: var(--np-bg);
  box-shadow: 0 24px 60px rgba(9, 15, 25, 0.3);
  animation: np-ck-pop 0.24s cubic-bezier(0.22, 1, 0.36, 1) both;
}
.np-login__close {
  position: absolute;
  top: 12px;
  right: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--np-muted);
  cursor: pointer;
}
.np-login__close:hover { background: var(--np-bg-soft); color: var(--np-text); }

.np-login__head { text-align: center; margin-bottom: 18px; }
.np-login__ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  margin-bottom: 10px;
  border-radius: 50%;
  background: var(--np-primary-soft);
  color: var(--np-primary);
}
.np-login__title { margin: 0 0 6px; font-size: 19px; font-weight: 700; color: var(--np-text); }
.np-login__sub { margin: 0; font-size: 12px; line-height: 1.7; color: var(--np-muted); }

.np-login__tabs { display: flex; gap: 4px; margin-bottom: 18px; border-bottom: 1px solid var(--np-line); }
.np-login__tabs button {
  flex: 1;
  padding: 9px 4px;
  border: 0;
  border-bottom: 2px solid transparent;
  background: transparent;
  color: var(--np-muted);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}
.np-login__tabs button.is-active { color: var(--np-primary); border-bottom-color: var(--np-primary); }

.np-login__msg {
  margin-bottom: 14px;
  padding: 9px 12px;
  border-radius: var(--np-radius-sm);
  font-size: 13px;
  line-height: 1.6;
}
.np-login__msg[hidden] { display: none; }
.np-login__msg.is-ok { background: rgba(29, 122, 61, 0.09); color: #1d7a3d; }
.np-login__msg.is-err { background: rgba(214, 54, 56, 0.09); color: var(--np-accent); }

.np-login__form .np-form-row { margin-bottom: 12px; }
.np-login__remember {
  display: flex;
  align-items: center;
  gap: 7px;
  margin: 2px 0 16px;
  font-size: 13px;
  color: var(--np-text-2);
  cursor: pointer;
}

.np-login__foot { margin-top: 18px; }
.np-login__links { display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: 12px; }
.np-login__links a { color: var(--np-muted); text-decoration: none; }
.np-login__links a:hover { color: var(--np-primary); }
.np-login__links a[hidden] { display: none; }
.np-login__or {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 16px 0 12px;
  color: var(--np-muted);
  font-size: 12px;
}
.np-login__or::before,
.np-login__or::after { content: ''; flex: 1; height: 1px; background: var(--np-line); }
.np-login__qq { width: 100%; }

/* 商品详情页 / 购物车页的「需要登录」提示 */
.np-product__login-tip,
.np-cart__login-tip {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin: 12px 0 0;
  padding: 10px 12px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg-soft);
  font-size: 12px;
  line-height: 1.65;
  color: var(--np-text-2);
}
.np-product__login-tip svg { flex: none; color: var(--np-primary); }
.np-product__login-tip span { flex: 1; min-width: 180px; }
.np-product__login-go,
.np-cart__login-go {
  flex: none;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--np-primary);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
}
.np-product__login-go:hover,
.np-cart__login-go:hover { text-decoration: underline; }
.np-cart__login-tip { display: block; }
.np-cart__login-tip .np-cart__login-go { margin-left: 6px; }

@media (max-width: 760px) {
  .np-login { padding: 0; align-items: flex-end; }
  .np-login__panel {
    width: 100%;
    max-height: 90vh;
    padding: 24px 18px 22px;
    border-radius: 16px 16px 0 0;
  }
  .np-product__login-tip span { min-width: 100%; }
}

/* ==========================================================================
   25. 手机商品页购买选项 / 用户投稿（1.8.29）
   ========================================================================== */

/* --- 商品页底部常驻操作条：私信入口 --- */
.np-product-bar__pm {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 42px;
  height: 40px;
  border: 1px solid var(--np-line);
  border-radius: 10px;
  color: var(--np-text-2);
  transition: background var(--np-transition), color var(--np-transition);
}

.np-product-bar__pm:hover { color: var(--np-primary); background: var(--np-bg-soft); }

.np-product-bar__pm .npm-toggle__badge {
  position: absolute;
  top: -6px;
  right: -6px;
  min-width: 16px;
  padding: 0 4px;
  border-radius: 999px;
  background: var(--np-accent);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  line-height: 16px;
  text-align: center;
}

/* 商品页隐藏全局底栏后，操作条常驻：补偿被遮住的内容 */
@media (max-width: 782px) {
  body.np-product-no-mnav.has-np-shop-bar { padding-bottom: calc(72px + env(safe-area-inset-bottom, 0px)); }
  body.np-product-no-mnav .np-product-bar { transform: none; }
  .np-product-bar { padding-left: 10px; padding-right: 10px; gap: 8px; }
  .np-product-bar__pm, .np-product-bar__cart { width: 38px; }
  .np-product-bar .np-btn { font-size: 13px; padding-left: 4px; padding-right: 4px; }
}

/* --- 购买选项弹窗（SKU 面板） --- */
.np-buy {
  position: fixed;
  inset: 0;
  z-index: 9997; /* 低于收银台 9998 与登录框 9999，提交后它们能正常盖上来 */
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.np-buy[hidden] { display: none; }

.np-buy__mask {
  position: absolute;
  inset: 0;
  background: rgba(12, 17, 24, 0.52);
  opacity: 0;
  transition: opacity 200ms ease;
}

.np-buy.is-open .np-buy__mask { opacity: 1; }

.np-buy__panel {
  position: relative;
  width: 100%;
  max-width: 520px;
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  border-radius: 18px 18px 0 0;
  background: var(--np-bg);
  box-shadow: 0 -12px 44px rgba(9, 15, 25, 0.24);
  transform: translateY(100%);
  transition: transform 260ms cubic-bezier(0.32, 0.72, 0, 1);
}

.np-buy.is-open .np-buy__panel { transform: translateY(0); }

@media (min-width: 783px) {
  .np-buy { align-items: center; }
  .np-buy__panel {
    max-height: 84vh;
    border-radius: 14px;
    transform: translateY(16px) scale(0.98);
    opacity: 0;
  }
  .np-buy.is-open .np-buy__panel { transform: translateY(0) scale(1); opacity: 1; }
}

.np-buy__close {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 50%;
  background: var(--np-bg-soft);
  color: var(--np-text-2);
  cursor: pointer;
}

.np-buy__head { display: flex; gap: 14px; padding: 20px 52px 14px 18px; }

.np-buy__thumb {
  flex: 0 0 auto;
  width: 88px;
  height: 88px;
  overflow: hidden;
  border: 1px solid var(--np-line);
  border-radius: 10px;
  background: var(--np-bg-soft);
}

.np-buy__thumb img { width: 100%; height: 100%; object-fit: cover; }
.np-buy__thumb-ph { display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; color: var(--np-muted); }

.np-buy__headinfo { min-width: 0; flex: 1; }
.np-buy__title { margin: 2px 0 8px; font-size: 14px; font-weight: 600; line-height: 1.5; color: var(--np-text); }
.np-buy__priceline { display: flex; align-items: baseline; gap: 8px; margin: 0 0 6px; }
.np-buy__priceline b { font-size: 22px; color: var(--np-accent); }
.np-buy__priceline s { font-size: 13px; color: var(--np-muted); }
.np-buy__picked { margin: 0; font-size: 12.5px; color: var(--np-muted); }

.np-buy__services { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 18px 12px; border-bottom: 1px solid var(--np-line); }
.np-buy__services span {
  padding: 3px 8px;
  border: 1px solid var(--np-line);
  border-radius: 4px;
  font-size: 11.5px;
  color: var(--np-text-2);
}

.np-buy__body { flex: 1; overflow-y: auto; padding: 16px 18px 8px; }
.np-buy__spec { margin-bottom: 18px; }
.np-buy__label { display: block; margin-bottom: 9px; font-size: 13.5px; font-weight: 600; color: var(--np-text); }
.np-buy__spec-vals { display: flex; flex-wrap: wrap; gap: 8px; }

.np-buy__spec-val {
  padding: 8px 13px;
  border: 1px solid var(--np-line);
  border-radius: 6px;
  background: var(--np-bg);
  color: var(--np-text-2);
  font-size: 13px;
  cursor: pointer;
  transition: var(--np-transition);
}

.np-buy__spec-val i { margin-left: 4px; font-style: normal; font-size: 11px; color: var(--np-accent); }
.np-buy__spec-val:hover { border-color: var(--np-primary); }
.np-buy__spec-val.is-active { border-color: var(--np-primary); background: var(--np-primary-soft); color: var(--np-primary); font-weight: 600; }

.np-buy__qty { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; margin-bottom: 12px; }
.np-buy__qty .np-buy__label { margin: 0; }
.np-buy__stepper { display: inline-flex; align-items: center; border: 1px solid var(--np-line); border-radius: 6px; overflow: hidden; }
.np-buy__stepper button { width: 34px; height: 34px; border: 0; background: var(--np-bg-soft); color: var(--np-text); font-size: 18px; cursor: pointer; }
.np-buy__stepper input { width: 46px; height: 34px; border: 0; border-left: 1px solid var(--np-line); border-right: 1px solid var(--np-line); text-align: center; font-size: 14px; background: var(--np-bg); color: var(--np-text); }
.np-buy__stock { font-size: 12.5px; color: var(--np-muted); }

.np-buy__msg { margin: 0 0 10px; padding: 8px 10px; border-radius: 6px; font-size: 13px; }
.np-buy__msg.is-err { background: rgba(214, 54, 56, 0.08); color: var(--np-accent); }
.np-buy__msg.is-ok { background: var(--np-primary-soft); color: var(--np-primary); }

.np-buy__foot {
  display: flex;
  gap: 10px;
  padding: 12px 18px calc(14px + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid var(--np-line);
}
.np-buy__foot .np-btn { flex: 1; min-height: 44px; }
.np-buy__cart { border-color: var(--np-primary); color: var(--np-primary); }
.np-buy__submit { background: var(--np-accent); border-color: var(--np-accent); }

html.np-buy-lock, body.np-buy-open { overflow: hidden; }

/* --- 用户投稿前台 --- */
.np-submit { max-width: 1040px; margin: 0 auto; padding: 20px 0 60px; }
.np-submit__hero { display: flex; gap: 16px; align-items: flex-start; padding: 20px; border: 1px solid var(--np-line); border-radius: 12px; background: var(--np-bg-soft); }
.np-submit__hero-icon { display: inline-flex; align-items: center; justify-content: center; flex: 0 0 auto; width: 48px; height: 48px; border-radius: 12px; background: var(--np-primary-soft); color: var(--np-primary); }
.np-submit__hero h1 { margin: 2px 0 6px; font-size: 20px; }
.np-submit__hero p { margin: 0; font-size: 13.5px; color: var(--np-muted); line-height: 1.7; }
.np-submit__note { margin: 14px 0; padding: 11px 14px; border-radius: 8px; font-size: 13.5px; }
.np-submit__note.is-ok { background: rgba(34, 163, 103, 0.1); color: #128a56; }
.np-submit__note.is-err { background: rgba(214, 54, 56, 0.09); color: var(--np-accent); }
.np-submit__login { margin-top: 18px; padding: 30px; text-align: center; border: 1px solid var(--np-line); border-radius: 12px; }
.np-submit__login h2 { margin: 0 0 8px; font-size: 17px; }
.np-submit__login p { margin: 0 0 18px; color: var(--np-muted); font-size: 13.5px; }
.np-submit__grid { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 18px; margin-top: 18px; }
.np-submit__panel { padding: 20px; border: 1px solid var(--np-line); border-radius: 12px; background: var(--np-bg); }
.np-submit__title { margin: 0 0 16px; font-size: 15px; }
.np-submit__two { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.np-submit__form .np-form-row em { color: var(--np-accent); font-style: normal; }
.np-submit__form select { width: 100%; height: 40px; padding: 0 10px; border: 1px solid var(--np-line); border-radius: var(--np-radius-sm); background: var(--np-bg); color: var(--np-text); font-size: 14px; }
.np-submit__count { margin-top: 6px; font-size: 12px; color: var(--np-muted); text-align: right; }
.np-submit__count .is-over { color: var(--np-accent); font-weight: 600; }
.np-submit__preview { position: relative; width: 140px; margin-bottom: 14px; }
.np-submit__preview img { width: 140px; height: 90px; object-fit: cover; border: 1px solid var(--np-line); border-radius: 8px; }
.np-submit__preview-del { position: absolute; top: -8px; right: -8px; width: 22px; height: 22px; border: 0; border-radius: 50%; background: var(--np-accent); color: #fff; cursor: pointer; }
.np-submit__foot { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.np-submit__tip { font-size: 12.5px; color: var(--np-muted); }
.np-submit__rules { margin: 0; padding-left: 18px; }
.np-submit__rules li { margin-bottom: 8px; font-size: 13px; line-height: 1.7; color: var(--np-text-2); }
.np-submit__empty { margin: 0; font-size: 13px; color: var(--np-muted); }
.np-submit__list { margin: 0; padding: 0; list-style: none; }
.np-submit__list li { padding: 10px 0; border-bottom: 1px dashed var(--np-line); }
.np-submit__list li:last-child { border-bottom: 0; }
.np-submit__row { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 13.5px; }
.np-submit__row a { color: var(--np-text); text-decoration: none; }
.np-submit__row a:hover { color: var(--np-primary); }
.np-submit__badge { flex: 0 0 auto; padding: 2px 8px; border-radius: 999px; background: var(--np-bg-soft); color: var(--np-muted); font-size: 11px; font-style: normal; }
.np-submit__badge.is-publish { background: rgba(34, 163, 103, 0.12); color: #128a56; }
.np-submit__badge.is-pending { background: rgba(230, 162, 60, 0.14); color: #b26a12; }
.np-submit__rowmeta { display: flex; align-items: center; justify-content: space-between; margin-top: 4px; font-size: 12px; color: var(--np-muted); }
.np-submit__withdraw { padding: 0; border: 0; background: none; color: var(--np-accent); font-size: 12px; cursor: pointer; }

@media (max-width: 900px) {
  .np-submit__grid { grid-template-columns: minmax(0, 1fr); }
  .np-submit__side { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 18px; align-content: start; }
}

@media (max-width: 560px) {
  .np-submit__hero { padding: 16px; }
  .np-submit__two { grid-template-columns: 1fr; }
  .np-submit__panel { padding: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  .np-buy__mask, .np-buy__panel { transition: none !important; }
}

/* ==========================================================================
   26. 1.8.30 SEO 站点图片 / 软件下载
   ========================================================================== */

/* --- 主题 SEO 设置的站点 Logo（只存 URL，不生成附件） ---
 * 1.8.35：尺寸改为读 CSS 变量，由「主题设置 → SEO → 站点身份」的滑块注入，
 * 不再写死 40/34/30px；max-width 按高度等比跟随，放大时不会被旧上限截断。 */
.np-brand__logo { display: inline-flex; align-items: center; max-height: var(--np-logo-h, 48px); }
.np-brand__logo img { display: block; max-height: var(--np-logo-h, 48px); max-width: 200px; width: auto; height: auto; object-fit: contain; }

/* --- 品牌区：Logo + 站点标题（+ 可选副标题），顶部导航 / 抽屉 / 页脚共用 --- */
.np-brand__link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  max-width: 100%;
  color: var(--np-text);
  text-decoration: none;
}
.np-brand__link:hover, .np-brand__link:focus { color: var(--np-text); text-decoration: none; }
.np-brand__img {
  display: block;
  flex: none;
  width: auto;
  height: auto;
  max-height: var(--np-logo-h, 40px);
  max-width: min(calc(var(--np-logo-h, 40px) * 4.5), 260px);
  object-fit: contain;
  transform: translateY(var(--np-logo-offset, 0px));
}
.np-brand__text {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
  line-height: 1.2;
}
.np-brand__title {
  display: block;
  min-width: 0;
  max-width: 260px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  /* 1.8.36：字号由「站点身份 → 电脑端站点标题字号」滑块注入。 */
  font-size: var(--np-title-size, 19px);
  font-weight: 800;
  letter-spacing: -0.3px;
  transition: color .18s ease;
}
.np-brand__link:hover .np-brand__title { color: var(--np-primary); }
.np-brand__tagline {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  margin-top: 3px;
  /* 1.8.36：字号由「站点身份 → 电脑端副标题字号」滑块注入。 */
  font-size: var(--np-tagline-size, 11px);
  font-weight: 400;
  color: var(--np-muted);
}
/* 手机抽屉：尺寸收一档，副标题不占位 */
.np-brand__link--drawer { gap: 9px; }
.np-brand__link--drawer .np-brand__img {
  max-height: var(--np-logo-h-mobile, 28px);
  max-width: min(calc(var(--np-logo-h-mobile, 28px) * 4), 44vw);
}
.np-brand__link--drawer .np-brand__title { font-size: var(--np-title-size-mobile, 16px); }
.np-brand__link--drawer .np-brand__tagline { font-size: var(--np-tagline-size-mobile, 10px); display: none; }

/* 手机端：用单独的 --np-logo-h-mobile，避免大图把站点标题挤出屏幕。
 * max-width 同时受高度倍数与视口宽度双重限制，横版长 Logo 也不会撑破头部。 */
@media (max-width: 960px) {
  .np-brand__link { gap: 8px; }
  .np-brand__img {
    max-height: var(--np-logo-h-mobile, 28px);
    max-width: min(calc(var(--np-logo-h-mobile, 28px) * 3.6), 38vw);
  }
  .np-brand__title { font-size: var(--np-title-size-mobile, 16px); max-width: min(150px, 34vw); }
  /* 副标题默认收起；勾选「手机端显示副标题」后由内联 CSS 覆盖为 block。 */
  .np-brand__tagline { font-size: var(--np-tagline-size-mobile, 10px); display: none; }
}
@media (max-width: 380px) {
  .np-brand__img {
    max-height: var(--np-logo-h-mobile, 28px);
    max-width: min(calc(var(--np-logo-h-mobile, 28px) * 3), 34vw);
  }
  /* 1.8.36：字号完全交给手机滑块，超窄屏只收紧可用宽度，不再写死 15px。 */
  .np-brand__title { max-width: min(120px, 30vw); }
}

/* --- 软件：公共 --- */
.np-soft-crumb { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 18px 0; font-size: 13px; color: var(--np-muted); }
.np-soft-crumb a { color: var(--np-muted); text-decoration: none; }
.np-soft-crumb a:hover { color: var(--np-primary); }
.np-soft-crumb > span:last-child { color: var(--np-text); }

.np-soft-archive { padding: 22px 0 10px; }
.np-soft-archive__title { margin: 0 0 6px; font-size: 26px; }
.np-soft-archive__count { margin: 0; color: var(--np-muted); font-size: 13px; }
.np-soft-archive__desc { margin-top: 12px; color: var(--np-text-2); font-size: 14px; line-height: 1.8; }

.np-soft-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 16px 0; }
.np-soft-chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 14px; border: 1px solid var(--np-line); border-radius: 999px; background: var(--np-bg); color: var(--np-text-2); font-size: 13px; text-decoration: none; transition: all .18s ease; }
.np-soft-chip:hover { border-color: var(--np-primary); color: var(--np-primary); }
.np-soft-chip.is-active { border-color: var(--np-primary); background: var(--np-primary-soft); color: var(--np-primary); font-weight: 600; }
.np-soft-chip i { font-style: normal; font-size: 11px; color: var(--np-muted); }
.np-soft-chips--plat .np-soft-chip { border-radius: 6px; }

.np-soft-sort { display: flex; gap: 18px; margin: 8px 0 20px; border-bottom: 1px solid var(--np-line); }
.np-soft-sort__item { padding: 8px 2px 12px; color: var(--np-muted); font-size: 13.5px; text-decoration: none; border-bottom: 2px solid transparent; }
.np-soft-sort__item:hover { color: var(--np-primary); }
.np-soft-sort__item.is-active { color: var(--np-primary); border-bottom-color: var(--np-primary); font-weight: 600; }

.np-soft-grid { display: grid; gap: 16px; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.np-soft-grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.np-soft-grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.np-soft-card { display: flex; flex-direction: column; overflow: hidden; border: 1px solid var(--np-line); border-radius: 12px; background: var(--np-bg); transition: transform .18s ease, box-shadow .18s ease; }
.np-soft-card:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0, 0, 0, .07); }
.np-soft-card__media { position: relative; display: flex; align-items: center; justify-content: center; height: 148px; padding: 18px; background: var(--np-bg-soft); }
.np-soft-card__icon { max-width: 96px; max-height: 96px; width: auto; height: auto; border-radius: 18px; object-fit: contain; }
.np-soft-card__ph { display: inline-flex; align-items: center; justify-content: center; width: 76px; height: 76px; border-radius: 18px; background: var(--np-primary-soft); color: var(--np-primary); font-size: 40px; }
.np-soft-card__ph svg, .np-soft__ph svg, .np-soft__icon--ph svg { width: 1em; height: 1em; }
.np-soft-card__lic { position: absolute; top: 10px; right: 10px; padding: 2px 9px; border-radius: 999px; background: var(--np-bg); color: var(--np-muted); font-size: 11px; }
.np-soft-card__body { display: flex; flex: 1; flex-direction: column; padding: 14px 16px 16px; }
.np-soft-card__title { margin: 0 0 6px; font-size: 15px; line-height: 1.5; }
.np-soft-card__title a { color: var(--np-text); text-decoration: none; }
.np-soft-card__title a:hover { color: var(--np-primary); }
.np-soft-card__meta { margin: 0 0 12px; color: var(--np-muted); font-size: 12px; }
.np-soft-card__foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: auto; padding-top: 10px; border-top: 1px dashed var(--np-line); }
.np-soft-card__count { color: var(--np-muted); font-size: 12px; }
.np-soft-card__go { color: var(--np-primary); font-size: 12.5px; font-weight: 600; text-decoration: none; }
.np-soft-empty { padding: 46px 20px; text-align: center; color: var(--np-muted); }

.np-soft__img-fallback { display: inline-flex; align-items: center; justify-content: center; width: 100%; height: 100%; min-height: 56px; background: var(--np-primary-soft); color: var(--np-primary); font-size: 34px; border-radius: 12px; }

/* --- 软件：详情页 --- */
.np-soft { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 26px; margin: 8px 0 30px; }
.np-soft__gallery { min-width: 0; }
.np-soft__stage { display: flex; align-items: center; justify-content: center; min-height: 320px; padding: 16px; border: 1px solid var(--np-line); border-radius: 12px; background: var(--np-bg-soft); }
.np-soft__shot { display: block; max-width: 100%; max-height: 380px; width: auto; height: auto; border-radius: 8px; object-fit: contain; }
.np-soft__ph { display: inline-flex; align-items: center; justify-content: center; width: 120px; height: 120px; border-radius: 20px; background: var(--np-primary-soft); color: var(--np-primary); font-size: 64px; }
.np-soft__thumbs { display: flex; gap: 10px; margin-top: 12px; overflow-x: auto; }
.np-soft__thumb { flex: 0 0 88px; height: 64px; padding: 0; border: 2px solid transparent; border-radius: 8px; background: var(--np-bg-soft); cursor: pointer; overflow: hidden; }
.np-soft__thumb.is-active { border-color: var(--np-primary); }
.np-soft__thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }

.np-soft__info { min-width: 0; }
.np-soft__heading { display: flex; gap: 14px; align-items: flex-start; }
.np-soft__icon { flex: 0 0 64px; width: 64px; height: 64px; border-radius: 14px; object-fit: contain; background: var(--np-bg-soft); }
.np-soft__icon--ph { display: inline-flex; align-items: center; justify-content: center; background: var(--np-primary-soft); color: var(--np-primary); font-size: 36px; }
.np-soft__title { margin: 0 0 8px; font-size: 23px; line-height: 1.35; }
.np-soft__ver { display: inline-block; margin-right: 8px; padding: 2px 8px; border-radius: 6px; background: var(--np-bg-soft); color: var(--np-muted); font-size: 12px; }
.np-soft__lic { display: inline-block; margin-right: 8px; padding: 2px 9px; border-radius: 999px; background: var(--np-primary-soft); color: var(--np-primary); font-size: 12px; }
.np-soft__lic--paid { background: rgba(230, 162, 60, .16); color: #b26a12; }
.np-soft__score { color: #e6a23c; font-size: 13px; white-space: nowrap; }
.np-soft__score i { margin-left: 5px; color: var(--np-muted); font-size: 12px; font-style: normal; }
.np-soft__sub { margin: 14px 0; color: var(--np-text-2); font-size: 14px; line-height: 1.8; }
.np-soft__platforms { display: flex; flex-wrap: wrap; gap: 6px; margin: 12px 0 16px; }
.np-soft__plat { padding: 3px 10px; border: 1px solid var(--np-line); border-radius: 6px; color: var(--np-text-2); font-size: 12px; }
.np-soft__specs { width: 100%; border-collapse: collapse; margin-bottom: 18px; }
.np-soft__specs th, .np-soft__specs td { padding: 8px 0; border-bottom: 1px dashed var(--np-line); text-align: left; font-size: 13px; vertical-align: top; }
.np-soft__specs th { width: 88px; color: var(--np-muted); font-weight: 400; white-space: nowrap; }
.np-soft__specs td { color: var(--np-text); word-break: break-all; }
.np-soft__specs a { color: var(--np-primary); text-decoration: none; }
.np-soft__downloads h2 { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin: 0 0 12px; font-size: 15px; }
.np-soft__vip-tag { padding: 2px 9px; border-radius: 999px; background: var(--np-accent-soft, rgba(214,54,56,.1)); color: var(--np-accent); font-size: 11.5px; font-weight: 500; }
.np-soft-card__vip { position: absolute; left: 10px; top: 10px; padding: 2px 9px; border-radius: 999px; background: var(--np-accent); color: #fff; font-size: 11px; }
/* --- 会员不足时的下载引导 --- */
.np-soft__vip { display: flex; align-items: flex-start; gap: 14px; padding: 18px; border: 1px solid var(--np-line); border-radius: 12px; background: var(--np-bg-soft); }
.np-soft__vip-ico { display: inline-flex; flex: 0 0 auto; width: 40px; height: 40px; align-items: center; justify-content: center; border-radius: 10px; background: var(--np-primary-soft); color: var(--np-primary); }
.np-soft__vip-txt { min-width: 0; }
.np-soft__vip-txt strong { display: block; margin-bottom: 6px; font-size: 14px; }
.np-soft__vip-txt p { margin: 0 0 12px; color: var(--np-muted); font-size: 12.5px; line-height: 1.7; }
.np-soft__vip-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.np-soft__vip-btn { display: inline-block; padding: 7px 16px; border: 1px solid var(--np-primary); border-radius: 8px; background: var(--np-primary); color: #fff; font-size: 13px; text-decoration: none; }
.np-soft__vip-btn.is-ghost { background: transparent; color: var(--np-primary); }
.np-soft__dl { display: flex; align-items: center; gap: 12px; width: 100%; margin-bottom: 8px; padding: 11px 14px; border: 1px solid var(--np-line); border-radius: 10px; background: var(--np-bg); color: var(--np-text); text-align: left; cursor: pointer; transition: all .18s ease; }
.np-soft__dl:hover:not(:disabled) { border-color: var(--np-primary); background: var(--np-primary-soft); }
.np-soft__dl:disabled { opacity: .65; cursor: default; }
.np-soft__dl-ico { display: inline-flex; flex: 0 0 auto; color: var(--np-primary); }
.np-soft__dl-txt { display: flex; flex-direction: column; min-width: 0; }
.np-soft__dl-txt strong { font-size: 13.5px; font-weight: 600; }
.np-soft__dl-txt i { color: var(--np-muted); font-size: 12px; font-style: normal; }
.np-soft__safety { margin: 8px 0 0; color: var(--np-muted); font-size: 12px; }
.np-soft__empty { color: var(--np-muted); font-size: 13px; }

.np-soft__below { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 22px; margin-bottom: 50px; }
.np-soft__section { padding: 22px; margin-bottom: 18px; border: 1px solid var(--np-line); border-radius: 12px; background: var(--np-bg); }
.np-soft__section > h2 { margin: 0 0 16px; font-size: 17px; }
.np-soft__log { margin: 0; padding-left: 18px; }
.np-soft__log li { margin-bottom: 8px; color: var(--np-text-2); font-size: 13.5px; line-height: 1.7; }
.np-soft__panel { padding: 18px; margin-bottom: 16px; border: 1px solid var(--np-line); border-radius: 12px; background: var(--np-bg); }
.np-soft__panel h3 { margin: 0 0 12px; font-size: 14px; }
.np-soft__tag { display: inline-block; margin: 0 6px 6px 0; padding: 4px 10px; border-radius: 6px; background: var(--np-bg-soft); color: var(--np-text-2); font-size: 12px; text-decoration: none; }
.np-soft__tag:hover { color: var(--np-primary); }
.np-soft__related { margin: 0; padding: 0; list-style: none; }
.np-soft__related li { display: flex; align-items: center; gap: 9px; padding: 8px 0; border-bottom: 1px dashed var(--np-line); font-size: 13px; }
.np-soft__related li:last-child { border-bottom: 0; }
.np-soft__related img { flex: 0 0 30px; width: 30px; height: 30px; border-radius: 7px; object-fit: contain; }
.np-soft__related a { flex: 1; min-width: 0; color: var(--np-text); text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.np-soft__related a:hover { color: var(--np-primary); }
.np-soft__related i { flex: 0 0 auto; color: var(--np-muted); font-size: 11px; font-style: normal; }
.np-soft__back { display: block; padding: 10px; border-radius: 8px; background: var(--np-primary-soft); color: var(--np-primary); font-size: 13px; font-weight: 600; text-align: center; text-decoration: none; }

/* --- 软件：软件库首页 --- */
.np-soft-home__hero { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 22px; padding: 28px; border: 1px solid var(--np-line); border-radius: 14px; background: var(--np-bg-soft); }
.np-soft-home__hero h1 { margin: 0 0 10px; font-size: 27px; }
.np-soft-home__hero p { max-width: 560px; margin: 0; color: var(--np-text-2); font-size: 14px; line-height: 1.8; }
.np-soft-home__stats { display: flex; gap: 24px; }
.np-soft-home__stats div { display: flex; flex-direction: column; gap: 3px; text-align: center; }
.np-soft-home__stats b { color: var(--np-primary); font-size: 22px; }
.np-soft-home__stats span { color: var(--np-muted); font-size: 12px; }
.np-soft-home__plats { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 10px; margin: 18px 0; }
.np-soft-home__plat { display: flex; align-items: center; gap: 10px; padding: 13px 14px; border: 1px solid var(--np-line); border-radius: 10px; background: var(--np-bg); color: var(--np-text); font-size: 13.5px; text-decoration: none; transition: all .18s ease; }
.np-soft-home__plat:hover { border-color: var(--np-primary); color: var(--np-primary); transform: translateY(-1px); }
.np-soft-home__plat-ico { display: inline-flex; color: var(--np-primary); }
.np-soft-home__sec { margin: 34px 0; }
.np-soft-home__sechead { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.np-soft-home__sechead h2 { margin: 0; font-size: 20px; }
.np-soft-home__sechead a { color: var(--np-primary); font-size: 13px; text-decoration: none; }
.np-soft-rank { margin: 0; padding: 0; list-style: none; border: 1px solid var(--np-line); border-radius: 12px; overflow: hidden; }
.np-soft-rank li { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-bottom: 1px dashed var(--np-line); font-size: 13.5px; }
.np-soft-rank li:last-child { border-bottom: 0; }
.np-soft-rank__no { flex: 0 0 24px; color: var(--np-muted); font-weight: 700; text-align: center; }
.np-soft-rank__no.is-top { color: var(--np-accent); }
.np-soft-rank img { flex: 0 0 36px; width: 36px; height: 36px; border-radius: 8px; object-fit: contain; }
.np-soft-rank a { flex: 1; min-width: 0; color: var(--np-text); text-decoration: none; }
.np-soft-rank a:hover { color: var(--np-primary); }
.np-soft-rank__meta { color: var(--np-muted); font-size: 12px; }
.np-soft-rank__count { color: var(--np-muted); font-size: 12px; white-space: nowrap; }

@media (max-width: 900px) {
  .np-soft { grid-template-columns: minmax(0, 1fr); }
  .np-soft__below { grid-template-columns: minmax(0, 1fr); }
  .np-soft-grid--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .np-soft-home__plats { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 560px) {
  .np-soft-archive__title, .np-soft-home__hero h1 { font-size: 22px; }
  .np-soft-grid, .np-soft-grid--2, .np-soft-grid--4 { grid-template-columns: minmax(0, 1fr); }
  .np-soft-home__hero { padding: 20px; }
  .np-soft-home__stats { gap: 18px; }
  .np-soft-home__plats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .np-soft__stage { min-height: 220px; }
  .np-soft-rank__meta { display: none; }
  .np-brand__logo img { max-width: min(calc(var(--np-logo-h-mobile, 28px) * 4), 150px); max-height: var(--np-logo-h-mobile, 28px); }
}

@media (prefers-reduced-motion: reduce) {
  .np-soft-card, .np-soft__dl, .np-soft-home__plat { transition: none !important; }
}

/* ==========================================================================
   27. 1.8.35 品牌区：页脚 Logo + 站点标题 / 手机端展示方式
   ========================================================================== */

/* 页脚改为与顶部导航共用 newspress_brand_html('footer')：图片在左、站点
 * 标题在右，不再只剩一张站点图标。页脚 Logo 比头部略小，但仍随滑块缩放。 */
.np-footer__brand .np-brand__link--footer {
  gap: 12px;
  color: var(--np-text);
}

.np-footer .np-brand__link--footer:hover,
.np-footer .np-brand__link--footer:focus { color: var(--np-primary); }

/* 1.8.41：页脚品牌区不再跟随「站点身份」的 7 个滑块，也不受「Logo 上下
 * 位置微调」影响，统一用一套固定尺寸，避免把滑块拉到极端时页脚被带歪。 */
.np-footer__brand .np-brand__link--footer .np-brand__img {
  max-height: 36px;
  max-width: min(220px, 60vw);
  transform: none;
}

.np-footer__brand .np-brand__link--footer .np-brand__title {
  font-size: 20px;
  max-width: min(320px, 60vw);
}

.np-footer__brand .np-brand__link--footer .np-brand__tagline {
  font-size: 12px;
}

/* 旧页脚 Logo 类保留给子主题 / 兜底分支，尺寸同样固定。 */
.np-footer__logo-img { max-height: 36px; transform: none; }

/* 手机端：页脚 Logo 改用手机尺寸；「手机端品牌区展示方式」让站长可以
 * 在手机上只留 Logo 或只留站点标题，电脑端完全不受影响。 */
@media (max-width: 960px) {
  .np-brand__link--mobile-logo-only .np-brand__text { display: none; }
  .np-brand__link--mobile-title-only .np-brand__img { display: none; }
  /* 1.8.41：隐藏整个品牌区。抽屉里的品牌 <a> 在 .np-nav 内，全局
   * .np-nav a{display:block} 特异性 0,1,1 会盖掉下面那条 0,1,0 的规则，
   * 所以额外用 .np-nav a.np-brand__link--mobile-hidden 提权到 0,2,1。 */
  .np-brand__link--mobile-hidden { display: none; }
  .np-nav a.np-brand__link--mobile-hidden { display: none !important; }

  /* 页脚品牌区固定尺寸，不受手机端展示方式与滑块影响。 */
  .np-footer__brand .np-brand__link--footer { gap: 10px; }
  .np-footer__brand .np-brand__link--footer .np-brand__img {
    max-height: 30px;
    max-width: min(160px, 52vw);
    transform: none;
  }
  .np-footer__brand .np-brand__link--footer .np-brand__title {
    font-size: 18px;
    max-width: min(220px, 52vw);
  }
  .np-footer__brand .np-brand__link--footer .np-brand__tagline { font-size: 12px; }
  .np-footer__logo-img { max-height: 30px; transform: none; }
  .np-auth__logo-img {
    max-height: calc(var(--np-logo-h-mobile, 28px) * 1.2);
    max-width: min(calc(var(--np-logo-h-mobile, 28px) * 4), 70vw);
  }
}

/* ==========================================================================
   28. 1.8.36 品牌区文字字号：站点标题 / 副标题滑块
   ==========================================================================

   「主题设置 → SEO → 站点身份」新增 4 个滑块，由 newspress_dynamic_css()
   注入 4 个 CSS 变量：
     --np-title-size           电脑端站点标题字号（默认 19px，12~40）
     --np-title-size-mobile    手机端站点标题字号（默认 16px，12~30）
     --np-tagline-size         电脑端副标题字号（默认 11px，9~20）
     --np-tagline-size-mobile  手机端副标题字号（默认 10px，9~18）

   前台所有品牌区的标题 / 副标题、抽屉、页脚与手机断点均改读这些变量，旧的
   写死 px 值保留为不支持 CSS 变量时的回退。手机端副标题默认仍收起，勾选
   「手机端显示副标题」后由 newspress_seo_mobile_tagline_css() 输出覆盖规则，
   抽屉不受影响。后台双视口预览与前台共用同一组变量名，所见即所得。
   ========================================================================== */

/* ==========================================================================
   29. 1.8.37 快捷工具：左下角固定侧边栏（顶部 / 侧边可切换）
   ==========================================================================

   工具组 DOM 只渲染一份，由 header.php 按「常规 → 快捷工具位置」输出到
   顶部 .np-header__inner 或左下角 .np-side-tools。侧边栏放在 </header> 外，
   避免吸顶头部的 backdrop-filter 把 position:fixed 困在头部层叠上下文里。

   桌面：竖排常驻 + 悬停显示名称；手机：收成一枚「工具」按钮，点开才展开，
   与右下角 .np-fab（返回顶部）、底部 .np-mnav 错开，互不遮挡。
   ========================================================================== */

.np-side-tools {
  position: fixed;
  left: 18px;
  bottom: 22px;
  z-index: 88;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
}

/* 桌面常驻展开，不需要折叠按钮 */
.np-side-tools__toggle { display: none; }

.np-side-tools__body {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  padding: 8px;
  border: 1px solid var(--np-line);
  border-radius: 14px;
  background: var(--np-bg);
  box-shadow: 0 6px 24px rgba(9, 14, 22, 0.14);
}

.np-side-tools .np-header__actions {
  flex-direction: column;
  gap: 8px;
  margin-left: 0;
  order: 0;
}

/* 统一成 40px 方形按钮，覆盖各模块里 34px / 31px 的默认尺寸 */
.np-side-tools .npm-toggle,
.np-side-tools .np-user-toggle,
.np-side-tools .np-cart-toggle,
.np-side-tools .np-search-toggle,
.np-side-tools .np-dark-toggle,
.np-side-tools .np-translate-toggle {
  position: relative;
  flex: none;
  width: 40px;
  height: 40px;
  border: 1px solid var(--np-line);
  border-radius: 10px;
  background: var(--np-bg);
  color: var(--np-text-2);
}

.np-side-tools .npm-toggle:hover,
.np-side-tools .np-user-toggle:hover,
.np-side-tools .np-cart-toggle:hover,
.np-side-tools .np-search-toggle:hover,
.np-side-tools .np-dark-toggle:hover,
.np-side-tools .np-translate-toggle:hover {
  color: var(--np-primary);
  border-color: var(--np-primary);
  background: var(--np-primary-soft);
}

/* 名称提示直接取按钮的 aria-label，不必在 PHP 里再写一份文案 */
.np-side-tools .np-header__actions > [aria-label]::after,
.np-side-tools .np-translate-toggle::after {
  content: attr(aria-label);
  position: absolute;
  left: calc(100% + 10px);
  top: 50%;
  z-index: 4;
  padding: 5px 10px;
  border-radius: 6px;
  background: var(--np-text);
  color: var(--np-bg);
  font-size: 12px;
  line-height: 1.4;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(-50%) translateX(-4px);
  transition: opacity .18s ease, transform .18s ease, visibility .18s ease;
}

.np-side-tools .np-header__actions > [aria-label]:hover::after,
.np-side-tools .np-header__actions > [aria-label]:focus-visible::after,
.np-side-tools .np-translate-toggle:hover::after,
.np-side-tools .np-translate-toggle:focus-visible::after {
  opacity: 1;
  visibility: visible;
  transform: translateY(-50%) translateX(0);
}

/* 翻译菜单展开时让位给菜单本身 */
.np-side-tools .np-translate-toggle[aria-expanded="true"]::after {
  opacity: 0;
  visibility: hidden;
}

.np-side-tools .np-translate-wrap { position: relative; flex: none; }

.np-side-tools .np-translate-menu {
  top: auto;
  right: auto;
  bottom: 0;
  left: calc(100% + 10px);
}

/* 搜索框跟着工具组搬到侧边栏内展开，不再从页面顶部掉下来 */
.np-side-tools .np-header__search {
  display: none;
  width: min(220px, calc(100vw - 80px));
  padding: 8px 0 2px;
  border: 0;
  background: transparent;
}

.np-side-tools .np-header__search.is-open { display: block; }
.np-side-tools .np-search-form { flex-direction: column; gap: 6px; }

@media (max-width: 960px) {
  .np-side-tools {
    left: 14px;
    bottom: calc(var(--np-mnav-h) + env(safe-area-inset-bottom, 0px) + 16px);
  }

  body:not(.np-mnav-on) .np-side-tools,
  body.np-bars-hidden .np-side-tools {
    bottom: calc(18px + env(safe-area-inset-bottom, 0px));
  }

  .np-side-tools__toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 1px solid var(--np-line);
    border-radius: 50%;
    background: var(--np-bg);
    color: var(--np-text-2);
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(9, 14, 22, 0.16);
    -webkit-tap-highlight-color: transparent;
  }

  .np-side-tools__icon-close { display: none; }
  .np-side-tools.is-open .np-side-tools__icon-open { display: none; }
  .np-side-tools.is-open .np-side-tools__icon-close { display: block; }

  .np-side-tools__body {
    display: none;
    max-height: calc(100vh - 170px);
    overflow-y: auto;
    overscroll-behavior: contain;
  }

  .np-side-tools.is-open .np-side-tools__body { display: flex; }

  /* 触屏没有 hover，名称提示直接关掉，避免挡住正文 */
  .np-side-tools .np-header__actions > [aria-label]::after,
  .np-side-tools .np-translate-toggle::after { display: none; }

  .np-side-tools .np-translate-menu { width: 168px; }
  .np-side-tools .np-header__search { width: min(200px, calc(100vw - 90px)); }
}

/* ==========================================================================
   30. 1.8.38 快捷工具：左右侧边栏 / 返回顶部并入 / 图标浮动交互
   ==========================================================================

   - 右下角侧边栏：位置镜像，名称气泡与翻译菜单改朝左展开。
   - 「返回顶部」并入工具条最后一格，常驻显示（不再等滚动 400px 才出现）。
   - 图标浮动：hover 时按钮整体上浮 + 阴影加深 + 图标轻微放大，名称气泡
     跟着浮出。旧版只有变色，没有「浮起来」的反馈，这次补齐。
   - 搜索与用户中心固定回顶部，不再出现在侧边栏里。
   ========================================================================== */

/* --- 侧边栏里的返回顶部：与其余按钮同尺寸、常驻、带主色 --- */
.np-side-tools .np-backtop {
  position: relative;
  display: flex;
  flex: none;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 1px solid transparent;
  border-radius: 10px;
  background: var(--np-primary);
  color: #fff;
  cursor: pointer;
  box-shadow: 0 4px 14px color-mix(in srgb, var(--np-primary) 32%, transparent);
  -webkit-tap-highlight-color: transparent;
}
.np-side-tools .np-backtop.is-visible { display: flex; }

/* --- 图标浮动：所有工具按钮（含返回顶部）统一 hover 反馈 --- */
.np-side-tools .npm-toggle,
.np-side-tools .np-user-toggle,
.np-side-tools .np-cart-toggle,
.np-side-tools .np-search-toggle,
.np-side-tools .np-dark-toggle,
.np-side-tools .np-translate-toggle,
.np-side-tools .np-backtop {
  box-shadow: 0 2px 7px rgba(9, 14, 22, 0.08);
  transition: transform .22s cubic-bezier(0.34, 1.4, 0.64, 1),
              box-shadow .22s ease, color .18s ease,
              border-color .18s ease, background .18s ease;
}
.np-side-tools .npm-toggle svg,
.np-side-tools .np-user-toggle svg,
.np-side-tools .np-cart-toggle svg,
.np-side-tools .np-search-toggle svg,
.np-side-tools .np-dark-toggle svg,
.np-side-tools .np-translate-toggle svg,
.np-side-tools .np-backtop svg {
  transition: transform .22s cubic-bezier(0.34, 1.4, 0.64, 1);
}
.np-side-tools .npm-toggle:hover,
.np-side-tools .np-user-toggle:hover,
.np-side-tools .np-cart-toggle:hover,
.np-side-tools .np-search-toggle:hover,
.np-side-tools .np-dark-toggle:hover,
.np-side-tools .np-translate-toggle:hover,
.np-side-tools .np-backtop:hover,
.np-side-tools .npm-toggle:focus-visible,
.np-side-tools .np-user-toggle:focus-visible,
.np-side-tools .np-cart-toggle:focus-visible,
.np-side-tools .np-search-toggle:focus-visible,
.np-side-tools .np-dark-toggle:focus-visible,
.np-side-tools .np-translate-toggle:focus-visible,
.np-side-tools .np-backtop:focus-visible {
  transform: translateY(-4px);
  box-shadow: 0 11px 24px rgba(9, 14, 22, 0.20);
  z-index: 5;
}
.np-side-tools .npm-toggle:hover svg,
.np-side-tools .np-user-toggle:hover svg,
.np-side-tools .np-cart-toggle:hover svg,
.np-side-tools .np-search-toggle:hover svg,
.np-side-tools .np-dark-toggle:hover svg,
.np-side-tools .np-translate-toggle:hover svg,
.np-side-tools .np-backtop:hover svg {
  transform: scale(1.12);
}
.np-side-tools .np-backtop:hover { color: #fff; }

/* --- 名称气泡：默认收在按钮身后，hover 时右移 + 上浮淡入 --- */
.np-side-tools .np-header__actions > [aria-label]::after,
.np-side-tools .np-translate-toggle::after,
.np-side-tools .np-backtop::after {
  content: attr(aria-label);
  position: absolute;
  left: calc(100% + 10px);
  top: 50%;
  z-index: 6;
  padding: 5px 10px;
  border-radius: 6px;
  background: var(--np-text);
  color: var(--np-bg);
  font-size: 12px;
  line-height: 1.4;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translate(-6px, -50%);
  transition: opacity .18s ease, transform .22s cubic-bezier(0.34, 1.4, 0.64, 1), visibility .18s ease;
}
.np-side-tools .np-header__actions > [aria-label]:hover::after,
.np-side-tools .np-header__actions > [aria-label]:focus-visible::after,
.np-side-tools .np-translate-toggle:hover::after,
.np-side-tools .np-translate-toggle:focus-visible::after,
.np-side-tools .np-backtop:hover::after,
.np-side-tools .np-backtop:focus-visible::after {
  opacity: 1;
  visibility: visible;
  transform: translate(0, calc(-50% - 3px));
}
.np-side-tools .np-translate-toggle[aria-expanded="true"]::after { opacity: 0; visibility: hidden; }

/* --- 右下角侧边栏：位置镜像，气泡与翻译菜单朝左展开 --- */
.np-side-tools--right {
  left: auto;
  right: 18px;
  align-items: flex-end;
}
.np-side-tools--right .np-side-tools__body,
.np-side-tools--right .np-header__actions { align-items: flex-end; }

.np-side-tools--right .np-header__actions > [aria-label]::after,
.np-side-tools--right .np-translate-toggle::after,
.np-side-tools--right .np-backtop::after {
  left: auto;
  right: calc(100% + 10px);
  transform: translate(6px, -50%);
}
.np-side-tools--right .np-header__actions > [aria-label]:hover::after,
.np-side-tools--right .np-header__actions > [aria-label]:focus-visible::after,
.np-side-tools--right .np-translate-toggle:hover::after,
.np-side-tools--right .np-translate-toggle:focus-visible::after,
.np-side-tools--right .np-backtop:hover::after,
.np-side-tools--right .np-backtop:focus-visible::after {
  transform: translate(0, calc(-50% - 3px));
}
.np-side-tools--right .np-translate-menu {
  top: auto;
  right: calc(100% + 10px);
  bottom: 0;
  left: auto;
}

@media (max-width: 960px) {
  body .np-side-tools--right { right: 14px; left: auto; }
  /* 触屏没有 hover，气泡（含返回顶部）全部收起，避免挡住正文 */
  .np-side-tools .np-header__actions > [aria-label]::after,
  .np-side-tools .np-translate-toggle::after,
  .np-side-tools .np-backtop::after { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .np-side-tools .npm-toggle,
  .np-side-tools .np-user-toggle,
  .np-side-tools .np-cart-toggle,
  .np-side-tools .np-search-toggle,
  .np-side-tools .np-dark-toggle,
  .np-side-tools .np-translate-toggle,
  .np-side-tools .np-backtop,
  .np-side-tools .npm-toggle svg,
  .np-side-tools .np-user-toggle svg,
  .np-side-tools .np-cart-toggle svg,
  .np-side-tools .np-search-toggle svg,
  .np-side-tools .np-dark-toggle svg,
  .np-side-tools .np-translate-toggle svg,
  .np-side-tools .np-backtop svg,
  .np-side-tools .np-header__actions > [aria-label]::after,
  .np-side-tools .np-translate-toggle::after,
  .np-side-tools .np-backtop::after {
    transition: none !important;
    transform: none !important;
  }
}

/* ==========================================================================
   31. 1.8.38 用户中心：商城式「我的」页面
   ==========================================================================

   结构：渐变会员头卡 → 权益条 → 四格资产 → 五格订单状态 → 常用服务九宫格
   → 原有功能卡片（套餐 / 订单 / 资料 / 密码 / QQ / 评论）。全部用 .np-uc
   命名空间，旧的 .np-account 样式留给其它页面与子主题，互不干扰。
   ========================================================================== */

.np-uc-wrap { padding: 24px 0 56px; }
.np-uc {
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-width: 960px;
  margin: 0 auto;
}

/* --- 会员头卡 --- */
.np-uc__hero {
  position: relative;
  overflow: hidden;
  padding: 26px 26px 32px;
  border-radius: 18px;
  color: #fff;
  background: linear-gradient(125deg, var(--np-primary) 0%, color-mix(in srgb, var(--np-primary) 58%, #7c3aed) 100%);
  box-shadow: 0 10px 30px color-mix(in srgb, var(--np-primary) 22%, transparent);
}
.np-uc__hero-deco {
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.10);
  pointer-events: none;
}
.np-uc__hero-deco--1 { width: 220px; height: 220px; top: -110px; right: -40px; }
.np-uc__hero-deco--2 { width: 130px; height: 130px; bottom: -80px; left: 38%; background: rgba(255, 255, 255, 0.07); }

.np-uc__hero-main { position: relative; z-index: 1; display: flex; align-items: center; gap: 16px; }
.np-uc__avatar {
  flex: none;
  display: block;
  width: 76px;
  height: 76px;
  padding: 3px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.28);
}
.np-uc__avatar-img { display: block; width: 100%; height: 100%; border-radius: 50%; object-fit: cover; background: #fff; }
.np-uc__hero-info { min-width: 0; }
.np-uc__hero-name { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; font-size: 21px; font-weight: 800; line-height: 1.3; }
.np-uc__level {
  padding: 3px 9px;
  border: 1px solid rgba(255, 255, 255, 0.32);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.20);
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}
.np-uc__hero-mail { margin-top: 4px; font-size: 13px; opacity: 0.86; word-break: break-all; }
.np-uc__hero-meta { display: flex; flex-wrap: wrap; gap: 5px 14px; margin-top: 8px; font-size: 11.5px; opacity: 0.78; }
.np-uc__hero-edit {
  position: absolute;
  z-index: 2;
  top: 24px;
  right: 22px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 11px;
  border: 1px solid rgba(255, 255, 255, 0.30);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  color: #fff;
  font-size: 12px;
  text-decoration: none;
}
.np-uc__hero-edit:hover { background: rgba(255, 255, 255, 0.30); color: #fff; }

/* --- 会员权益条：压在头卡下缘 --- */
.np-uc__vip {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: -22px 18px 0;
  padding: 13px 16px;
  border-radius: 13px;
  background: linear-gradient(100deg, #2b2833, #4b4155);
  color: #f6e4b2;
  box-shadow: 0 8px 22px rgba(20, 16, 28, 0.20);
}
.np-uc__vip-left { display: flex; align-items: center; gap: 11px; min-width: 0; }
.np-uc__vip-ico {
  flex: none;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: rgba(246, 213, 138, 0.13);
  color: #f6d58a;
}
.np-uc__vip-left strong { display: block; font-size: 14px; color: #f9e9c1; }
.np-uc__vip-left span { display: block; margin-top: 2px; font-size: 11.5px; color: rgba(246, 228, 178, 0.72); }
.np-uc__vip-cta {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 7px 12px;
  border-radius: 999px;
  background: linear-gradient(100deg, #f7dfa6, #e9bf70);
  color: #3b2f1c;
  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
}
.np-uc__vip-cta:hover { color: #3b2f1c; filter: brightness(1.06); }

/* --- 资产概览 --- */
.np-uc__assets { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.np-uc__asset {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 13px 6px;
  border: 1px solid var(--np-line);
  border-radius: 12px;
  background: var(--np-bg);
  color: var(--np-text);
  text-decoration: none;
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.np-uc__asset:hover {
  transform: translateY(-2px);
  border-color: var(--np-primary);
  color: var(--np-primary);
  box-shadow: 0 8px 18px rgba(9, 14, 22, 0.08);
}
.np-uc__asset strong { font-size: 20px; font-weight: 800; line-height: 1.2; }
.np-uc__asset span { font-size: 11.5px; color: var(--np-muted); }

/* --- 通用区块 --- */
.np-uc__block,
.np-uc__panel {
  border: 1px solid var(--np-line);
  border-radius: 14px;
  background: var(--np-bg);
}
.np-uc__block { padding: 16px 16px 18px; }
.np-uc__block-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 14px; }
.np-uc__block-head h2 { margin: 0; font-size: 16px; font-weight: 800; }
.np-uc__block-head > a { display: inline-flex; align-items: center; gap: 3px; color: var(--np-muted); font-size: 12px; text-decoration: none; }
.np-uc__block-head > a:hover { color: var(--np-primary); }
.np-uc__block-tip { font-size: 11.5px; color: var(--np-muted); }

/* --- 订单状态五格 --- */
.np-uc__orders { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; }
.np-uc__order {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 6px 2px;
  border-radius: 10px;
  color: var(--np-text);
  text-decoration: none;
  transition: background .18s ease, color .18s ease;
}
.np-uc__order:hover { background: var(--np-bg-soft); color: var(--np-primary); }
.np-uc__order-ico {
  position: relative;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 14px;
  color: #fff;
}
.np-uc__order-label { font-size: 12px; white-space: nowrap; }
.np-uc__dot {
  position: absolute;
  top: -5px;
  right: -6px;
  min-width: 17px;
  height: 17px;
  padding: 0 4px;
  border-radius: 999px;
  background: var(--np-accent);
  box-shadow: 0 0 0 2px var(--np-bg);
  color: #fff;
  font-size: 10px;
  font-style: normal;
  font-weight: 700;
  line-height: 17px;
  text-align: center;
}

/* --- 常用服务九宫格 --- */
.np-uc__grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; }
.np-uc__tool {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 9px;
  padding: 15px 4px 13px;
  border: 1px solid transparent;
  border-radius: 12px;
  background: var(--np-bg-soft);
  color: var(--np-text);
  text-decoration: none;
  transition: transform .18s ease, background .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.np-uc__tool:hover {
  transform: translateY(-3px);
  border-color: var(--np-line);
  background: var(--np-bg);
  color: var(--np-primary);
  box-shadow: 0 8px 20px rgba(9, 14, 22, 0.08);
}
.np-uc__tool-ico {
  position: relative;
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  color: #fff;
}
.np-uc__tool-label { font-size: 12px; white-space: nowrap; }

/* 图标底色：色彩区分功能分组，深浅色模式下都保持足够对比 */
.np-uc__tone--blue   { background: linear-gradient(135deg, #4f9cf9, #2563eb); }
.np-uc__tone--orange { background: linear-gradient(135deg, #fbaf52, #f2761b); }
.np-uc__tone--pink   { background: linear-gradient(135deg, #fb8fb1, #e8457c); }
.np-uc__tone--red    { background: linear-gradient(135deg, #fb7b72, #e0392f); }
.np-uc__tone--amber  { background: linear-gradient(135deg, #f5cd6a, #d99b1c); }
.np-uc__tone--purple { background: linear-gradient(135deg, #a58bf5, #7048d9); }
.np-uc__tone--teal   { background: linear-gradient(135deg, #4cc9bd, #0f9a8d); }
.np-uc__tone--indigo { background: linear-gradient(135deg, #7a91e8, #3f51b5); }
.np-uc__tone--green  { background: linear-gradient(135deg, #6dcc77, #2f9e56); }
.np-uc__tone--cyan   { background: linear-gradient(135deg, #54c5e0, #1688ad); }
.np-uc__tone--slate  { background: linear-gradient(135deg, #8aa0b8, #5a718c); }
.np-uc__tone--gray   { background: linear-gradient(135deg, #a3aab4, #737d89); }

/* --- 原有功能卡片 --- */
.np-uc__panel { padding: 18px 20px 20px; scroll-margin-top: 84px; }
.np-uc__panel-head { margin-bottom: 14px; padding-bottom: 12px; border-bottom: 1px solid var(--np-line); }
.np-uc__panel-head h2 { margin: 0 0 4px; font-size: 16px; font-weight: 800; }
.np-uc__panel-head span { font-size: 12px; color: var(--np-muted); }

.np-uc__foot { display: flex; justify-content: center; padding: 4px 0 10px; }
.np-uc__logout {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 22px;
  border: 1px solid var(--np-line);
  border-radius: 999px;
  background: var(--np-bg);
  color: var(--np-muted);
  font-size: 13px;
  text-decoration: none;
}
.np-uc__logout:hover { border-color: var(--np-accent); color: var(--np-accent); }

@media (max-width: 760px) {
  .np-uc-wrap { padding: 14px 0 40px; }
  .np-uc { gap: 12px; }
  .np-uc__hero { padding: 18px 16px 28px; border-radius: 14px; }
  .np-uc__avatar { width: 60px; height: 60px; }
  .np-uc__hero-name { font-size: 18px; }
  .np-uc__hero-edit { top: auto; bottom: 16px; right: 14px; padding: 5px 9px; font-size: 11px; }
  .np-uc__vip { margin: -18px 10px 0; padding: 11px 12px; }
  .np-uc__vip-left strong { font-size: 13px; }
  .np-uc__assets { gap: 6px; }
  .np-uc__asset { padding: 10px 3px; }
  .np-uc__asset strong { font-size: 17px; }
  .np-uc__asset span { font-size: 11px; }
  .np-uc__block { padding: 13px 10px 15px; }
  .np-uc__orders { gap: 2px; }
  .np-uc__order-ico { width: 38px; height: 38px; border-radius: 12px; }
  .np-uc__order-label { font-size: 11px; }
  .np-uc__grid { grid-template-columns: repeat(4, 1fr); gap: 6px; }
  .np-uc__tool { gap: 7px; padding: 12px 2px 11px; }
  .np-uc__tool-ico { width: 38px; height: 38px; border-radius: 12px; }
  .np-uc__tool-label { font-size: 11px; }
  .np-uc__panel { padding: 15px 14px 17px; }
}
@media (max-width: 380px) {
  .np-uc__order-label, .np-uc__tool-label { font-size: 10px; }
  .np-uc__vip-cta { padding: 6px 9px; font-size: 11px; }
}

/* ==========================================================================
   32. 1.8.39 工具按钮可拖动定位
   ==========================================================================

   - 按钮本身是定位锚点：JS 把 left / top 写成 inline 样式（bottom/right:auto），
     位置按视口百分比存 localStorage，翻页、刷新、横竖屏都能还原且不出界。
   - 展开面板改为相对按钮绝对定位，默认向上展开；按钮被拖到视口上半部时
     （--drop-down）改为向下，拖到右半部时（--at-right）改为右对齐向左展开，
     这样拖到任何位置面板都不会伸出屏幕，也不会把按钮自己挤走。
   - 长按复位的小提示用 --toast，独立于面板，收起状态也能看到。
   - 只有 data-np-drag 不等于 off 才启用，选「关闭拖动」时完全回到 1.8.38 行为。
   ========================================================================== */

/* --- 拖动把手：禁用浏览器手势，避免按住拖动时页面跟着滚 --- */
.np-side-tools[data-np-drag]:not([data-np-drag="off"]) .np-side-tools__toggle {
  touch-action: none;
  cursor: grab;
  user-select: none;
  -webkit-user-select: none;
  -webkit-touch-callout: none;
}
.np-side-tools--dragging { transition: none !important; }
.np-side-tools--dragging .np-side-tools__toggle {
  cursor: grabbing;
  transform: scale(1.08);
  border-color: var(--np-primary);
  color: var(--np-primary);
  box-shadow: 0 10px 28px rgba(9, 14, 22, 0.28);
}
/* 拖动过的位置：容器由 top 定位，去掉底部留白带来的位移感 */
.np-side-tools--moved { will-change: left, top; }

/* --- 复位提示气泡 --- */
.np-side-tools__toast {
  position: absolute;
  left: 50%;
  bottom: calc(100% + 10px);
  z-index: 120;
  padding: 6px 12px;
  border-radius: 8px;
  background: var(--np-text);
  color: var(--np-bg);
  font-size: 12px;
  line-height: 1.5;
  white-space: nowrap;
  pointer-events: none;
  box-shadow: 0 6px 18px rgba(9, 14, 22, 0.2);
  transform: translateX(-50%);
  animation: np-tools-toast-in .2s ease-out;
}
.np-side-tools--drop-down .np-side-tools__toast {
  top: calc(100% + 10px);
  bottom: auto;
}
@keyframes np-tools-toast-in {
  from { opacity: 0; transform: translate(-50%, 6px); }
  to   { opacity: 1; transform: translate(-50%, 0); }
}

/* --- 桌面端 all 范围：拖到右半部时气泡与翻译菜单朝左展开 --- */
.np-side-tools--at-right .np-header__actions > [aria-label]::after,
.np-side-tools--at-right .np-translate-toggle::after,
.np-side-tools--at-right .np-backtop::after {
  left: auto;
  right: calc(100% + 10px);
  transform: translate(6px, -50%);
}
.np-side-tools--at-right .np-header__actions > [aria-label]:hover::after,
.np-side-tools--at-right .np-header__actions > [aria-label]:focus-visible::after,
.np-side-tools--at-right .np-translate-toggle:hover::after,
.np-side-tools--at-right .np-translate-toggle:focus-visible::after,
.np-side-tools--at-right .np-backtop:hover::after,
.np-side-tools--at-right .np-backtop:focus-visible::after {
  transform: translate(0, calc(-50% - 3px));
}
.np-side-tools--at-right .np-translate-menu {
  top: auto;
  right: calc(100% + 10px);
  bottom: 0;
  left: auto;
}

@media (max-width: 960px) {
  /* 面板脱离普通流，容器尺寸恒等于那枚 44px 按钮，拖到哪都不会被面板推走 */
  .np-side-tools[data-np-drag]:not([data-np-drag="off"]) .np-side-tools__body {
    position: absolute;
    left: 0;
    right: auto;
    top: auto;
    bottom: calc(100% + 8px);
    max-height: min(62vh, calc(100vh - 96px));
    z-index: 5;
  }
  /* 按钮在右半部 / 选了右下角侧边栏：面板改为向左展开 */
  .np-side-tools[data-np-drag]:not([data-np-drag="off"]).np-side-tools--at-right .np-side-tools__body,
  .np-side-tools[data-np-drag]:not([data-np-drag="off"]).np-side-tools--right .np-side-tools__body {
    left: auto;
    right: 0;
  }
  /* 按钮在视口上半部：面板改为向下展开 */
  .np-side-tools[data-np-drag]:not([data-np-drag="off"]).np-side-tools--drop-down .np-side-tools__body {
    top: calc(100% + 8px);
    bottom: auto;
  }
  .np-side-tools[data-np-drag]:not([data-np-drag="off"]) .np-side-tools__body {
    width: max-content;
    min-width: 56px;
  }
  .np-side-tools--at-right .np-translate-menu { left: auto; right: calc(100% + 10px); }
}

@media (prefers-reduced-motion: reduce) {
  .np-side-tools--dragging .np-side-tools__toggle { transform: none !important; }
  .np-side-tools__toast { animation: none !important; transition: none !important; }
}

/* ==========================================================================
   33. 1.8.40 明暗切换显示位置（抽屉 / 快捷工具可分别开关）
   --------------------------------------------------------------------------
   本版不新增布局样式：三处明暗入口（手机抽屉顶栏、快捷工具组、顶部模式下
   右下角悬浮组）都改由 PHP 条件渲染控制，隐藏其中任意一处都不会留下空位——
   .np-drawer__top-btns 与 .np-header__actions 本身就是 flex + gap，少一枚
   按钮会自动收拢。因此这里只留版本说明，不追加任何 display 规则，避免和
   既有的 .np-dark-toggle / .np-drawer__dark / .np-fab__dark 图标切换样式冲突。
   ========================================================================== */


/* ==========================================================================
   34. 1.8.41 用户中心：多多式「我的订单」面板
   ==========================================================================

   点「我的订单」五格状态 / 查看全部 / 累计订单 / 常用服务，JS 会拦截原来
   的 #np-account-orders 锚点，就地打开这个带状态筛选的面板，不再把访客
   甩到页面最底部；底部完整明细表格原样保留。手机端是整屏 bottom sheet，
   桌面端是居中弹窗，tab 切换只做显示 / 隐藏，不重新请求数据。

   页脚品牌区固定尺寸的规则已改在 27. 1.8.35 章节，这里不重复定义。
   ========================================================================== */

.np-orders-sheet[hidden] { display: none !important; }
.np-orders-sheet {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}
body.np-orders-open { overflow: hidden; }

.np-orders-sheet__mask {
  position: absolute;
  inset: 0;
  background: rgba(15, 18, 26, .55);
  backdrop-filter: blur(2px);
}
.np-orders-sheet__panel {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;
  height: min(88vh, 780px);
  max-width: 560px;
  background: var(--np-bg, #fff);
  border-radius: 18px 18px 0 0;
  box-shadow: 0 -12px 40px rgba(0, 0, 0, .22);
  overflow: hidden;
  animation: npOrdersIn .22s ease both;
}
@keyframes npOrdersIn {
  from { transform: translateY(24px); opacity: .6; }
  to { transform: translateY(0); opacity: 1; }
}
.np-orders-sheet__head {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px 12px;
  border-bottom: 1px solid var(--np-line, #e8ebf0);
}
.np-orders-sheet__head h2 { margin: 0; font-size: 17px; font-weight: 800; color: var(--np-text, #1c2230); }
.np-orders-sheet__close {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 50%;
  background: var(--np-bg-soft, #f3f5f9);
  color: var(--np-text-2, #6b7280);
  cursor: pointer;
}
.np-orders-sheet__tabs {
  flex: none;
  display: flex;
  gap: 6px;
  padding: 10px 14px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  border-bottom: 1px solid var(--np-line, #e8ebf0);
}
.np-orders-sheet__tabs::-webkit-scrollbar { display: none; }
.np-orders-sheet__tab {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 7px 13px;
  border: 0;
  border-radius: 999px;
  background: var(--np-bg-soft, #f3f5f9);
  color: var(--np-text-2, #6b7280);
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  transition: background .18s ease, color .18s ease;
}
.np-orders-sheet__tab em {
  font-style: normal;
  font-size: 10.5px;
  line-height: 1;
  min-width: 15px;
  padding: 2px 4px;
  border-radius: 8px;
  background: rgba(0, 0, 0, .07);
}
.np-orders-sheet__tab.is-active { background: var(--np-primary, #e1251b); color: #fff; }
.np-orders-sheet__tab.is-active em { background: rgba(255, 255, 255, .24); }
.np-orders-sheet__body {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 12px 14px calc(18px + env(safe-area-inset-bottom, 0px));
  background: var(--np-bg-soft, #f6f7f9);
}
.np-orders-sheet__card[hidden] { display: none !important; }
.np-orders-sheet__card {
  display: block;
  margin-bottom: 10px;
  padding: 12px 14px;
  border: 1px solid var(--np-line, #e8ebf0);
  border-radius: 12px;
  background: var(--np-bg, #fff);
}
.np-orders-sheet__card-top { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.np-orders-sheet__no { font-size: 11px; color: var(--np-muted, #98a0ad); margin-right: auto; }
.np-orders-sheet__card-main {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 10px 0;
}
.np-orders-sheet__title {
  min-width: 0;
  font-size: 14px;
  font-weight: 700;
  color: var(--np-text, #1c2230);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.np-orders-sheet__amount { flex: none; font-size: 15px; font-weight: 800; color: var(--np-primary, #e1251b); }
.np-orders-sheet__card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding-top: 9px;
  border-top: 1px dashed var(--np-line, #e8ebf0);
}
.np-orders-sheet__card-foot time { font-size: 11px; color: var(--np-muted, #98a0ad); }
.np-orders-sheet__act { flex: none; font-size: 12px; font-weight: 700; color: var(--np-primary, #e1251b); text-decoration: none; }
.np-orders-sheet__empty { margin: 36px 0; text-align: center; font-size: 13px; color: var(--np-muted, #98a0ad); }
.np-orders-sheet__empty[hidden] { display: none !important; }

@media (min-width: 721px) {
  .np-orders-sheet { align-items: center; }
  .np-orders-sheet__panel {
    height: min(76vh, 700px);
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, .28);
  }
}
@media (prefers-reduced-motion: reduce) {
  .np-orders-sheet__panel { animation: none; }
}

/* ==========================================================================
   36. 1.8.48 用户中心：常用服务就地弹层
   ==========================================================================

   「会员套餐 / 我的评论 / 资料设置 / 账号安全 / QQ 绑定」原来是锚点，点一下
   就滚到页面最底部。现在 JS 拦截后把对应功能区块整块搬进这个弹层，视觉沿用
   1.8.41 的订单面板；层级压到 9990，保证在「会员套餐」里点购买时，收银台
   (9998) 和登录框 (9999) 仍能盖在弹层上面。
   ========================================================================== */

body.np-service-open { overflow: hidden; }
.np-orders-sheet--service { z-index: 9990; }
/* 五个功能长短差别很大（套餐卡片 vs 一行表单），高度随内容自适应，
   只有内容超高才在弹层内滚动，避免短内容下方留一大片空白。 */
.np-orders-sheet--service .np-orders-sheet__panel {
  max-width: 720px;
  height: auto;
  min-height: min(360px, 60vh);
  max-height: min(88vh, 780px);
}
@media (min-width: 721px) {
  .np-orders-sheet--service .np-orders-sheet__panel { max-height: min(80vh, 760px); }
}

/* 搬进弹层的原功能区块：去掉外层卡片感，避免双层边框与双份留白 */
.np-service-sheet__body .np-uc__panel {
  border: 0;
  border-radius: 0;
  background: transparent;
  padding: 2px 2px 10px;
  scroll-margin-top: 0;
}
.np-service-sheet__body .np-uc__panel-head { margin-bottom: 12px; }
.np-service-sheet__body .np-vip-plan-grid,
.np-service-sheet__body .np-vip-plan-grid--compact,
.np-service-sheet__body .np-vip-plan-grid:has(.np-vip-plan:nth-child(4)) {
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
}
@media (max-width: 600px) {
  .np-service-sheet__body .np-vip-plan-grid,
  .np-service-sheet__body .np-vip-plan-grid--compact,
  .np-service-sheet__body .np-vip-plan-grid:has(.np-vip-plan:nth-child(4)) {
    grid-template-columns: 1fr !important;
  }
}
.np-service-sheet__body .np-auth__form,
.np-service-sheet__body .np-qq-unbind { max-width: 460px; }
.np-service-sheet__body .np-form-row input,
.np-service-sheet__body .np-form-row textarea { width: 100%; }
.np-service-sheet__body .np-account__comments { margin: 0; }
.np-orders-sheet--service .np-orders-sheet__tabs { scroll-behavior: smooth; }

/* ==========================================================================
   35. 1.8.42 工具按钮拖动：补齐电脑端
   ==========================================================================

   1.8.39 只做了手机端：桌面端 .np-side-tools__toggle 被隐藏（工具条常驻展开），
   而 JS 的拖动把手正是这枚按钮；此外常驻展开的 .np-side-tools__body 占了几百
   像素高，容器被当成定位锚点时几乎拖不动。

   这里在 all 范围、桌面宽度下：
   - 显示一枚 44px 圆形拖动把手，工具面板改为相对容器绝对定位（仍常驻展开），
     于是容器尺寸恒等于把手，place() / onMove() 的边界计算与手机端完全一致；
   - 沿用 1.8.39 的四象限类：右半屏朝左展开、上半屏向下展开；
   - 桌面端把手的 close 图标本来只在手机 media 里被隐藏，这里显式收掉，
     避免显示把手后两枚图标叠在一起；
   - 提示文案走 data-np-drag-tip，保持可翻译。
   ========================================================================== */

@media (min-width: 961px) {
  .np-side-tools[data-np-drag="all"] .np-side-tools__toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 1px solid var(--np-line);
    border-radius: 50%;
    background: var(--np-bg);
    color: var(--np-text-2);
    cursor: grab;
    box-shadow: 0 4px 14px rgba(9, 14, 22, 0.16);
    -webkit-tap-highlight-color: transparent;
  }

  /* 桌面端工具面板常驻展开，但脱离普通流，不参与容器尺寸计算 */
  .np-side-tools[data-np-drag="all"] .np-side-tools__body {
    position: absolute;
    left: 0;
    right: auto;
    top: auto;
    bottom: calc(100% + 8px);
    width: max-content;
    min-width: 56px;
    max-height: min(70vh, calc(100vh - 96px));
    overflow-y: auto;
    overscroll-behavior: contain;
    z-index: 5;
  }
  .np-side-tools[data-np-drag="all"].np-side-tools--at-right .np-side-tools__body,
  .np-side-tools[data-np-drag="all"].np-side-tools--right .np-side-tools__body {
    left: auto;
    right: 0;
  }
  .np-side-tools[data-np-drag="all"].np-side-tools--drop-down .np-side-tools__body {
    top: calc(100% + 8px);
    bottom: auto;
  }

  /* 桌面端把手只用于拖动：始终显示九点格，点一下不折叠面板 */
  .np-side-tools[data-np-drag="all"] .np-side-tools__icon-close { display: none; }
  .np-side-tools[data-np-drag="all"] .np-side-tools__icon-open { display: block; }

  /* 悬停提示：说明这枚按钮是拖动把手 */
  .np-side-tools[data-np-drag="all"] .np-side-tools__toggle::after {
    content: attr(data-np-drag-tip);
    position: absolute;
    left: calc(100% + 10px);
    top: 50%;
    z-index: 6;
    padding: 5px 10px;
    border-radius: 6px;
    background: var(--np-text);
    color: var(--np-bg);
    font-size: 12px;
    line-height: 1.4;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(-50%) translateX(-4px);
    transition: opacity .18s ease, transform .18s ease, visibility .18s ease;
  }
  .np-side-tools[data-np-drag="all"] .np-side-tools__toggle { position: relative; }
  .np-side-tools[data-np-drag="all"] .np-side-tools__toggle:hover::after,
  .np-side-tools[data-np-drag="all"] .np-side-tools__toggle:focus-visible::after {
    opacity: 1;
    visibility: visible;
    transform: translateY(-50%) translateX(0);
  }
  .np-side-tools[data-np-drag="all"].np-side-tools--at-right .np-side-tools__toggle::after {
    left: auto;
    right: calc(100% + 10px);
    transform: translateY(-50%) translateX(4px);
  }
  .np-side-tools[data-np-drag="all"].np-side-tools--at-right .np-side-tools__toggle:hover::after,
  .np-side-tools[data-np-drag="all"].np-side-tools--at-right .np-side-tools__toggle:focus-visible::after {
    transform: translateY(-50%) translateX(0);
  }
}


/* ==========================================================================
   36. 1.8.43 用户中心会员卡精修 + 电脑版工具栏默认收起
   ==========================================================================

   本版只处理观感，不动 DOM / 锚点 / 表单 / 拖动逻辑：
   - 用户中心：蓝头卡与深紫会员条由「负边距叠压 + 左右缩边」改为同宽紧贴、
     共享圆角的一张完整会员卡；皇冠由暗色描边方块改为金色圆形实心徽章；
     各区块尺寸整体收敛，解决「太大」「这里有问题」。
   - 电脑版工具栏：1.8.42 的 35 章让面板常驻展开以便拖动，视觉上却留下一条
     200+px 白板 + 分离的圆把手。这里在 961px 以上把面板默认 display:none，
     点 .is-open 才展开，把手改成主色渐变悬浮按钮；35 章的定位 / 四象限 /
     气泡规则全部保留，拖动行为不变。
   ========================================================================== */

/* --- 会员卡：同宽贴合成一张卡，整体收紧 --- */
.np-uc__hero {
  padding: 20px 24px 20px;
  border-radius: 18px 18px 0 0;
  box-shadow: 0 4px 14px color-mix(in srgb, var(--np-primary) 16%, transparent);
}
.np-uc__vip {
  margin: -16px 0 0; /* 抵消 .np-uc 的 gap:16px，与头卡贴合 */
  padding: 11px 20px;
  border-radius: 0 0 18px 18px;
  box-shadow: 0 10px 24px rgba(20, 16, 28, 0.16);
}
.np-uc__avatar { width: 64px; height: 64px; padding: 2px; }
.np-uc__hero-name { font-size: 19px; gap: 8px; }
.np-uc__hero-mail { font-size: 12.5px; }
.np-uc__hero-meta { font-size: 11px; }
.np-uc__hero-edit { top: 18px; right: 20px; padding: 5px 10px; font-size: 11.5px; }

/* --- 皇冠：金色渐变圆徽章 + 实心皇冠，不再像一块暗洞 ---
   注意 .np-uc__vip-left span 的 (0,2,1) 规则会给这枚 span 塞进
   display:block / color / margin-top / font-size，必须用更高特异性覆盖。 */
.np-uc .np-uc__vip-left span.np-uc__vip-ico {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  margin-top: 0;
  border-radius: 50%;
  background: linear-gradient(135deg, #fbe3ad, #e2b25c);
  color: #6a4a16;
  font-size: initial;
  line-height: 1;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.20);
}
.np-uc .np-uc__vip-left span.np-uc__vip-ico svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
  stroke: none;
}
.np-uc__vip-left { gap: 10px; }
.np-uc__vip-left strong { font-size: 13.5px; }
.np-uc__vip-left span { font-size: 11px; }
.np-uc__vip-cta { padding: 6px 11px; font-size: 11.5px; }

/* --- 下方区块同步收紧 --- */
.np-uc__assets { gap: 8px; }
.np-uc__asset { padding: 11px 6px; border-radius: 11px; }
.np-uc__asset strong { font-size: 18px; }
.np-uc__asset span { font-size: 11px; }
.np-uc__block { padding: 14px 16px 16px; }
.np-uc__block-head { margin-bottom: 12px; }
.np-uc__block-head h2 { font-size: 15px; }
.np-uc__orders { gap: 4px; }
.np-uc__order { gap: 6px; padding: 5px 2px; }
.np-uc__order-ico { width: 40px; height: 40px; border-radius: 12px; }
.np-uc__order-label { font-size: 11.5px; }
.np-uc__tool-ico { width: 40px; height: 40px; }

/* --- 手机端：同样拼接成整卡并收紧（断点与 31 章一致，gap 为 12px） --- */
@media (max-width: 760px) {
  .np-uc__hero { padding: 16px 14px 18px; border-radius: 14px 14px 0 0; }
  .np-uc__avatar { width: 54px; height: 54px; }
  .np-uc__hero-name { font-size: 17px; }
  /* 底部绝对定位会和 ID / 加入日期那行挤在一起，改成右上角圆形图标按钮 */
  .np-uc__hero-info { padding-right: 38px; }
  .np-uc__hero-edit {
    top: 12px;
    right: 12px;
    bottom: auto;
    width: 30px;
    height: 30px;
    padding: 0;
    justify-content: center;
    border-radius: 50%;
    font-size: 0;
  }
  .np-uc__hero-edit svg { width: 14px; height: 14px; flex: none; }
  .np-uc__vip { margin: -12px 0 0; padding: 10px 14px; border-radius: 0 0 14px 14px; }
  .np-uc .np-uc__vip-left span.np-uc__vip-ico { width: 26px; height: 26px; }
  .np-uc .np-uc__vip-left span.np-uc__vip-ico svg { width: 15px; height: 15px; }
  .np-uc__vip-left strong { font-size: 13px; }
  .np-uc__vip-left span { font-size: 10.5px; }
  .np-uc__vip-cta { padding: 6px 9px; font-size: 11px; }
  .np-uc__assets { gap: 6px; }
  .np-uc__asset { padding: 9px 3px; }
  .np-uc__asset strong { font-size: 16px; }
  .np-uc__asset span { font-size: 10.5px; }
  .np-uc__block { padding: 12px 10px 14px; }
  .np-uc__orders { gap: 2px; }
  .np-uc__order-ico { width: 36px; height: 36px; border-radius: 11px; }
  .np-uc__tool-ico { width: 36px; height: 36px; border-radius: 11px; }
}

/* --- 拖动把手精修：主色渐变悬浮按钮，电脑 / 手机端 all 模式统一 --- */
.np-side-tools[data-np-drag="all"] .np-side-tools__toggle {
  border: none;
  background: linear-gradient(135deg, var(--np-primary), color-mix(in srgb, var(--np-primary) 62%, #7c3aed));
  color: #fff;
  box-shadow: 0 6px 18px color-mix(in srgb, var(--np-primary) 40%, transparent);
}
.np-side-tools[data-np-drag="all"] .np-side-tools__toggle:hover { filter: brightness(1.08); }
.np-side-tools[data-np-drag="all"] .np-side-tools__toggle::after { background: rgba(24, 28, 38, 0.92); }

/* --- 电脑版工具栏：默认只留一枚悬浮按钮，点开才展开 --- */
@media (min-width: 961px) {
  .np-side-tools[data-np-drag="all"] .np-side-tools__body { display: none; }
  .np-side-tools[data-np-drag="all"].is-open .np-side-tools__body { display: flex; }

  /* 展开时把手图标变关闭，语义更清楚 */
  .np-side-tools[data-np-drag="all"].is-open .np-side-tools__icon-open { display: none; }
  .np-side-tools[data-np-drag="all"].is-open .np-side-tools__icon-close { display: block; }

  /* 展开面板轻盈化：半透明毛玻璃 + 细边框，按钮收敛到 36px */
  .np-side-tools[data-np-drag="all"] .np-side-tools__body {
    padding: 6px;
    gap: 4px;
    border: 1px solid var(--np-line);
    border-radius: 16px;
    background: color-mix(in srgb, var(--np-bg) 93%, transparent);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    box-shadow: 0 12px 32px rgba(9, 14, 22, 0.18);
  }
  .np-side-tools[data-np-drag="all"] .np-side-tools .np-header__actions { gap: 4px; }
  .np-side-tools[data-np-drag="all"] .npm-toggle,
  .np-side-tools[data-np-drag="all"] .np-user-toggle,
  .np-side-tools[data-np-drag="all"] .np-cart-toggle,
  .np-side-tools[data-np-drag="all"] .np-search-toggle,
  .np-side-tools[data-np-drag="all"] .np-dark-toggle,
  .np-side-tools[data-np-drag="all"] .np-translate-toggle {
    width: 36px;
    height: 36px;
    border-color: transparent;
    border-radius: 10px;
    background: transparent;
  }
  .np-side-tools[data-np-drag="all"] .np-side-tools__backtop { width: 36px; height: 36px; }
}

/* ==========================================================================
   37. 1.8.44 最近动态 / 用户中心顶部留白 / 主题介绍购买页
   ==========================================================================

   37.1 用户中心：原来 .np-main 的 24px 与 .np-uc-wrap 的 14px 上下叠加，
        手机端导航与蓝色会员卡之间空出近 40px。这里把顶部留白压到 6px，
        并用一条「最近动态」细条把这块位置用起来（细条可在设置里关掉）。
   -------------------------------------------------------------------------- */
body.np-page-account .np-main { padding-top: 0; }
body.np-page-account .np-uc-wrap { padding-top: 10px; }
@media (max-width: 760px) {
  body.np-page-account .np-uc-wrap { padding-top: 6px; }
}

/* --- 37.2 最近动态：卡片版（首页模块） --- */
.np-module__sub {
  margin-left: auto;
  font-size: 12px;
  font-weight: 400;
  color: var(--np-muted);
}

.np-activity {
  --np-activity-speed: 30s;
  --np-activity-rows: 3;
  --np-activity-count: 6;
  --np-activity-row-h: 52px;
  position: relative;
  overflow: hidden;
  border: 1px solid var(--np-line);
  border-radius: 14px;
  background: var(--np-bg);
  box-shadow: 0 2px 12px rgba(16, 24, 40, 0.04);
}
.np-activity__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 14px 16px 12px;
  border-bottom: 1px solid var(--np-line);
}
.np-activity__head-main { display: flex; align-items: baseline; flex-wrap: wrap; gap: 10px; min-width: 0; }
.np-activity__head h2 { margin: 0; font-size: 16px; font-weight: 800; }
.np-activity__sub { font-size: 12px; color: var(--np-muted); }
.np-activity__pulse {
  flex: none;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--np-accent);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--np-accent) 16%, transparent);
  animation: np-activity-pulse 2.2s ease-in-out infinite;
}
@keyframes np-activity-pulse {
  0%, 100% { box-shadow: 0 0 0 3px color-mix(in srgb, var(--np-accent) 16%, transparent); }
  50%      { box-shadow: 0 0 0 7px color-mix(in srgb, var(--np-accent) 6%, transparent); }
}
.np-activity__more { flex: none; font-size: 12px; color: var(--np-muted); text-decoration: none; }
.np-activity__more:hover { color: var(--np-primary); }

.np-activity__viewport {
  height: min(calc(var(--np-activity-rows) * var(--np-activity-row-h)), calc(var(--np-activity-count) * var(--np-activity-row-h)));
  overflow: hidden;
}
.np-activity__track { animation: np-activity-scroll var(--np-activity-speed) linear infinite; will-change: transform; }
.np-activity--static .np-activity__track { animation: none; }
.np-activity:not(.np-activity--static) .np-activity__viewport:hover .np-activity__track,
.np-activity:not(.np-activity--static) .np-activity__viewport:focus-within .np-activity__track { animation-play-state: paused; }
@keyframes np-activity-scroll {
  from { transform: translateY(0); }
  to   { transform: translateY(-50%); }
}

.np-activity__item {
  display: flex;
  align-items: center;
  gap: 11px;
  box-sizing: border-box;
  height: var(--np-activity-row-h);
  padding: 0 16px;
  border-bottom: 1px dashed var(--np-line);
  color: var(--np-text);
  text-decoration: none;
  transition: background var(--np-transition);
}
a.np-activity__item:hover { background: var(--np-bg-soft); }
.np-activity__dot {
  flex: none;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--np-primary);
  box-shadow: 0 0 0 3px var(--np-primary-soft);
}
.np-activity__body { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1; }
.np-activity__body strong {
  overflow: hidden;
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1.4;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.np-activity__meta { font-size: 11px; color: var(--np-muted); }
.np-activity__arrow { flex: none; color: var(--np-muted); opacity: 0; transition: opacity var(--np-transition), transform var(--np-transition); }
a.np-activity__item:hover .np-activity__arrow { opacity: 1; transform: translateX(2px); }

/* --- 37.3 最近动态：用户中心顶部单行细条 --- */
.np-activity--bar {
  --np-activity-rows: 1;
  --np-activity-row-h: 34px;
  display: flex;
  align-items: center;
  gap: 10px;
  height: 40px;
  padding: 0 12px;
  border-color: transparent;
  border-radius: 12px;
  background: linear-gradient(100deg, color-mix(in srgb, var(--np-primary) 10%, var(--np-bg)), color-mix(in srgb, var(--np-primary) 3%, var(--np-bg)));
  box-shadow: none;
}
.np-activity__bar-label {
  display: inline-flex;
  flex: none;
  align-items: center;
  gap: 4px;
  padding: 3px 8px;
  border-radius: 999px;
  background: var(--np-primary);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}
.np-activity--bar .np-activity__viewport { flex: 1; min-width: 0; }
.np-activity--bar .np-activity__item { gap: 8px; padding: 0; border-bottom: 0; background: transparent; }
.np-activity--bar .np-activity__item:hover { background: transparent; }
.np-activity--bar .np-activity__dot { width: 5px; height: 5px; box-shadow: none; }
.np-activity--bar .np-activity__body { flex-direction: row; align-items: baseline; gap: 8px; }
.np-activity--bar .np-activity__body strong { font-size: 12px; font-weight: 600; }
.np-activity--bar .np-activity__meta { flex: none; font-size: 10.5px; }
.np-activity--bar .np-activity__arrow { display: none; }

@media (max-width: 760px) {
  .np-activity__head { padding: 12px 12px 10px; }
  .np-activity__head h2 { font-size: 15px; }
  .np-activity__item { padding: 0 12px; }
  .np-activity__body strong { font-size: 12.5px; }
  .np-activity--bar { height: 38px; padding: 0 10px; gap: 8px; }
  .np-activity--bar .np-activity__meta { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .np-activity__track { animation: none !important; }
  .np-activity__pulse { animation: none; }
}
body.np-dark .np-activity { box-shadow: none; }
body.np-dark .np-activity--bar {
  background: linear-gradient(100deg, color-mix(in srgb, var(--np-primary) 18%, var(--np-bg)), color-mix(in srgb, var(--np-primary) 5%, var(--np-bg)));
}

/* --- 37.4 主题介绍 / 购买页 --- */
body.np-page-buy .np-main { padding: 0; }
.np-tbuy { overflow: hidden; }

/* 主视觉 */
.np-tbuy__hero {
  position: relative;
  overflow: hidden;
  padding: 62px 0 70px;
  color: #fff;
  background: linear-gradient(122deg, #101a33 0%, color-mix(in srgb, var(--np-primary) 78%, #14213d) 52%, #6d3fd4 118%);
}
.np-tbuy__deco { position: absolute; border-radius: 50%; pointer-events: none; }
.np-tbuy__deco--1 { width: 460px; height: 460px; top: -230px; right: -90px; background: rgba(255, 255, 255, 0.09); }
.np-tbuy__deco--2 { width: 260px; height: 260px; bottom: -160px; left: 22%; background: rgba(255, 255, 255, 0.06); }
.np-tbuy__hero-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 48px;
  align-items: center;
}
.np-tbuy__eyebrow {
  display: inline-block;
  padding: 5px 12px;
  border: 1px solid rgba(255, 255, 255, 0.32);
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: rgba(255, 255, 255, 0.9);
}
.np-tbuy__hero h1 { margin: 18px 0 12px; font-size: 40px; font-weight: 800; line-height: 1.25; letter-spacing: -0.02em; }
.np-tbuy__tagline { max-width: 620px; margin: 0; font-size: 15px; line-height: 1.9; color: rgba(255, 255, 255, 0.82); }
.np-tbuy__highlights { display: flex; flex-wrap: wrap; gap: 10px 22px; margin: 22px 0 0; padding: 0; list-style: none; }
.np-tbuy__highlights li { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: rgba(255, 255, 255, 0.92); }
.np-tbuy__highlights svg { color: #8ff0c0; }
.np-tbuy__hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.np-tbuy__hero-note { margin: 16px 0 0; font-size: 12px; color: rgba(255, 255, 255, 0.62); }

/* 按钮：四种配色，页面内所有 CTA 共用 */
.np-tbuy__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 11px 22px;
  border: 1px solid transparent;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: transform var(--np-transition), box-shadow var(--np-transition), filter var(--np-transition);
}
.np-tbuy__btn:hover { transform: translateY(-2px); }
.np-tbuy__btn--light { background: #fff; color: var(--np-primary-dark, #135e96); box-shadow: 0 8px 24px rgba(0, 0, 0, 0.14); }
.np-tbuy__btn--outline { border-color: rgba(255, 255, 255, 0.5); color: #fff; background: rgba(255, 255, 255, 0.06); }
.np-tbuy__btn--outline:hover { background: rgba(255, 255, 255, 0.16); }
.np-tbuy__btn--primary { background: linear-gradient(135deg, var(--np-primary), color-mix(in srgb, var(--np-primary) 62%, #7c3aed)); color: #fff; box-shadow: 0 8px 20px color-mix(in srgb, var(--np-primary) 32%, transparent); }
.np-tbuy__btn--primary:hover { filter: brightness(1.08); }
.np-tbuy__btn--soft { background: var(--np-primary-soft); color: var(--np-primary); }
.np-tbuy__btn--soft:hover { background: color-mix(in srgb, var(--np-primary) 16%, transparent); }
.np-tbuy__btn--block { width: 100%; }

/* 价格卡 */
.np-tbuy__card {
  padding: 22px;
  border-radius: 18px;
  background: var(--np-bg);
  color: var(--np-text);
  box-shadow: 0 20px 50px rgba(6, 12, 24, 0.28);
}
.np-tbuy__card-head { display: flex; align-items: center; justify-content: space-between; font-size: 13px; font-weight: 700; color: var(--np-muted); }
.np-tbuy__badge { padding: 3px 9px; border-radius: 999px; background: color-mix(in srgb, var(--np-accent) 14%, transparent); color: var(--np-accent); font-size: 11px; }
.np-tbuy__price { display: flex; align-items: baseline; gap: 10px; margin: 10px 0 18px; }
.np-tbuy__price strong { font-size: 34px; font-weight: 800; line-height: 1.1; color: var(--np-accent); }
.np-tbuy__price del { font-size: 14px; color: var(--np-muted); }
.np-tbuy__card .np-tbuy__btn + .np-tbuy__btn { margin-top: 9px; }
.np-tbuy__meta {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px 12px;
  margin: 20px 0 0;
  padding: 18px 0 0;
  border-top: 1px solid var(--np-line);
  list-style: none;
}
.np-tbuy__meta li { min-width: 0; }
.np-tbuy__meta span { display: block; margin-bottom: 3px; font-size: 11px; color: var(--np-muted); }
.np-tbuy__meta strong { display: block; font-size: 12.5px; font-weight: 700; line-height: 1.5; word-break: break-word; }

/* 通用分节 */
.np-tbuy__section { padding: 66px 0; }
.np-tbuy__section--alt { background: var(--np-bg-soft); }
.np-tbuy__section-head { max-width: 720px; margin: 0 auto 36px; text-align: center; }
.np-tbuy__kicker { display: block; margin-bottom: 8px; font-size: 11px; font-weight: 800; letter-spacing: 0.2em; color: var(--np-primary); }
.np-tbuy__section-head h2 { margin: 0 0 10px; font-size: 28px; font-weight: 800; }
.np-tbuy__section-head p { margin: 0; font-size: 14px; color: var(--np-muted); }

/* 特色功能 */
.np-tbuy__grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.np-tbuy__feature {
  padding: 22px 20px;
  border: 1px solid var(--np-line);
  border-radius: 14px;
  background: var(--np-bg);
  transition: transform var(--np-transition), box-shadow var(--np-transition), border-color var(--np-transition);
}
.np-tbuy__feature:hover { transform: translateY(-4px); border-color: color-mix(in srgb, var(--np-primary) 40%, var(--np-line)); box-shadow: var(--np-shadow); }
.np-tbuy__feature-ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: linear-gradient(135deg, color-mix(in srgb, var(--np-primary) 16%, transparent), color-mix(in srgb, var(--np-primary) 6%, transparent));
  color: var(--np-primary);
}
.np-tbuy__feature h3 { margin: 15px 0 7px; font-size: 15px; font-weight: 800; }
.np-tbuy__feature p { margin: 0; font-size: 12.5px; line-height: 1.8; color: var(--np-muted); }

/* 更多功能 */
.np-tbuy__more-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
.np-tbuy__more-col { padding: 20px 18px; border: 1px solid var(--np-line); border-radius: 14px; background: var(--np-bg); }
.np-tbuy__more-col h3 { margin: 0 0 14px; padding-bottom: 12px; border-bottom: 1px solid var(--np-line); font-size: 15px; font-weight: 800; }
.np-tbuy__more-col ul { margin: 0; padding: 0; list-style: none; }
.np-tbuy__more-col li { display: flex; align-items: flex-start; gap: 8px; padding: 6px 0; font-size: 12.5px; line-height: 1.6; color: var(--np-text-2); }
.np-tbuy__more-col li svg { flex: none; margin-top: 3px; color: var(--np-primary); }

/* 附赠服务 */
.np-tbuy__service-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.np-tbuy__service {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 20px;
  border: 1px solid var(--np-line);
  border-radius: 14px;
  background: var(--np-bg);
}
.np-tbuy__service-ico {
  display: inline-flex;
  flex: none;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: color-mix(in srgb, var(--np-primary) 12%, transparent);
  color: var(--np-primary);
}
.np-tbuy__service h3 { margin: 2px 0 6px; font-size: 15px; font-weight: 800; }
.np-tbuy__service p { margin: 0; font-size: 12.5px; line-height: 1.75; color: var(--np-muted); }

/* 常见问题 */
.np-tbuy__faq-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 24px; }
.np-tbuy__faq-col h3 { margin: 0 0 12px; font-size: 15px; font-weight: 800; }
.np-tbuy__faq-item { margin-bottom: 10px; border: 1px solid var(--np-line); border-radius: 11px; background: var(--np-bg); overflow: hidden; }
.np-tbuy__faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 13px 15px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  list-style: none;
}
.np-tbuy__faq-item summary::-webkit-details-marker { display: none; }
.np-tbuy__faq-item summary svg { flex: none; color: var(--np-muted); transition: transform var(--np-transition); }
.np-tbuy__faq-item[open] summary { color: var(--np-primary); }
.np-tbuy__faq-item[open] summary svg { transform: rotate(45deg); color: var(--np-primary); }
.np-tbuy__faq-answer { padding: 0 15px 14px; font-size: 12.5px; line-height: 1.85; color: var(--np-text-2); }

/* 底部 CTA */
.np-tbuy__cta { padding: 40px 0; background: var(--np-bg-soft); }
.np-tbuy__cta-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 30px 34px;
  border-radius: 18px;
  color: #fff;
  background: linear-gradient(115deg, var(--np-primary), color-mix(in srgb, var(--np-primary) 58%, #7c3aed));
  box-shadow: 0 14px 34px color-mix(in srgb, var(--np-primary) 26%, transparent);
}
.np-tbuy__cta h2 { margin: 0 0 8px; font-size: 23px; font-weight: 800; }
.np-tbuy__cta p { margin: 0; font-size: 13px; color: rgba(255, 255, 255, 0.82); }
.np-tbuy__cta-actions { display: flex; flex: none; gap: 10px; }
.np-tbuy__cta-actions .np-tbuy__btn--primary { background: #fff; color: var(--np-primary-dark, #135e96); box-shadow: none; }
.np-tbuy__cta-actions .np-tbuy__btn--soft { background: rgba(255, 255, 255, 0.16); color: #fff; }
.np-tbuy__content { padding: 44px 0; }
.np-tbuy__notice { padding: 16px 0; border-top: 1px solid var(--np-line); font-size: 12px; line-height: 1.8; color: var(--np-muted); text-align: center; }

@media (max-width: 1024px) {
  .np-tbuy__hero-inner { grid-template-columns: minmax(0, 1fr) 300px; gap: 28px; }
  .np-tbuy__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .np-tbuy__more-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 760px) {
  .np-tbuy__hero { padding: 38px 0 44px; }
  .np-tbuy__hero-inner { grid-template-columns: minmax(0, 1fr); gap: 26px; }
  .np-tbuy__hero h1 { font-size: 27px; }
  .np-tbuy__tagline { font-size: 13.5px; }
  .np-tbuy__highlights { gap: 8px 14px; }
  .np-tbuy__highlights li { font-size: 12px; }
  .np-tbuy__hero-actions { margin-top: 22px; }
  .np-tbuy__btn { padding: 10px 18px; font-size: 13px; }
  .np-tbuy__card { padding: 18px; }
  .np-tbuy__price strong { font-size: 29px; }
  .np-tbuy__section { padding: 42px 0; }
  .np-tbuy__section-head { margin-bottom: 26px; }
  .np-tbuy__section-head h2 { font-size: 22px; }
  .np-tbuy__grid, .np-tbuy__more-grid, .np-tbuy__service-grid, .np-tbuy__faq-grid { grid-template-columns: minmax(0, 1fr); }
  .np-tbuy__feature { padding: 18px 16px; }
  .np-tbuy__cta { padding: 24px 0; }
  .np-tbuy__cta-inner { flex-direction: column; align-items: stretch; gap: 18px; padding: 24px 20px; }
  .np-tbuy__cta h2 { font-size: 20px; }
  .np-tbuy__cta-actions { flex-wrap: wrap; }
  .np-tbuy__cta-actions .np-tbuy__btn { flex: 1; }
}

/* ==========================================================================
   37. 1.8.49 文章互动条（点赞 / 赞赏 / 分享 / 收藏）
   一条横排四格的正文末尾操作条 + 两个就地弹层，全部跟随主题明暗令牌。
   ========================================================================== */

.np-pa {
  margin: 30px 0 10px;
  border-radius: var(--np-radius);
  overflow: hidden;
  transition: background var(--np-transition), border-color var(--np-transition);
}
.np-pa--dark {
  background: linear-gradient(135deg, #262b33 0%, #1d2128 100%);
  border: 1px solid rgba(255, 255, 255, 0.07);
  color: #e9ecf1;
  box-shadow: 0 10px 30px rgba(12, 16, 22, 0.14);
}
.np-pa--light {
  background: var(--np-bg-soft);
  border: 1px solid var(--np-line);
  color: var(--np-text);
}
body.np-dark .np-pa--dark {
  background: linear-gradient(135deg, #232a33 0%, #191f26 100%);
  border-color: rgba(255, 255, 255, 0.05);
}

.np-pa__bar {
  display: flex;
  align-items: stretch;
  padding: 18px 8px 12px;
}
.np-pa__act {
  position: relative;
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 8px 4px 10px;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  cursor: pointer;
  border-radius: var(--np-radius-sm);
  transition: color var(--np-transition), background var(--np-transition), transform var(--np-transition);
}
.np-pa__act + .np-pa__act::before {
  content: '';
  position: absolute;
  left: 0;
  top: 18%;
  height: 64%;
  width: 1px;
  background: currentColor;
  opacity: 0.09;
}
.np-pa__act:hover {
  background: rgba(127, 140, 160, 0.13);
  transform: translateY(-2px);
}
.np-pa--light .np-pa__act:hover { background: rgba(34, 113, 177, 0.07); }
.np-pa__act:focus-visible { outline: 2px solid var(--np-primary); outline-offset: -2px; }
.np-pa__act.is-busy { opacity: 0.55; pointer-events: none; }

.np-pa__ico { display: block; height: 26px; line-height: 0; }
.np-pa__ico svg { display: block; transition: transform var(--np-transition); }
.np-pa__act:hover .np-pa__ico svg { transform: translateY(-2px); }
.np-pa__act.is-active .np-pa__ico svg { fill: currentColor; fill-opacity: 0.18; }

.np-pa__label {
  font-size: 13.5px;
  line-height: 1.4;
  white-space: nowrap;
  letter-spacing: 0.2px;
}
.np-pa__count {
  font-style: normal;
  font-size: 12px;
  opacity: 0.72;
  margin-left: 2px;
  font-variant-numeric: tabular-nums;
}
.np-pa__act.is-active .np-pa__count { opacity: 1; }

.np-pa__act--reward { color: #ff5c9a; }
.np-pa__act--like.is-active { color: #ff8a5c; }
.np-pa__act--favorite.is-active { color: #ffc34d; }
.np-pa__act--like { --np-pa-on: #ff8a5c; }
.np-pa__act--share:hover { color: #7fb2f0; }

.np-pa__tip {
  margin: 0;
  padding: 0 12px 16px;
  text-align: center;
  font-size: 12px;
  opacity: 0.58;
  letter-spacing: 0.2px;
}

/* ---------- 就地弹层 ---------- */
body.np-pa-open { overflow: hidden; }
.np-pa-sheet[hidden] { display: none !important; }
.np-pa-sheet {
  position: fixed;
  inset: 0;
  z-index: 9995; /* 低于收银台 9998、登录框 9999，保证赞赏后仍能付款 */
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.np-pa-sheet__mask {
  position: absolute;
  inset: 0;
  background: rgba(9, 13, 18, 0.62);
  backdrop-filter: blur(3px);
}
.np-pa-sheet__panel {
  position: relative;
  width: min(420px, 100%);
  max-height: min(86vh, 760px);
  overflow: auto;
  background: var(--np-bg);
  color: var(--np-text);
  border-radius: 14px;
  box-shadow: 0 20px 60px rgba(6, 10, 16, 0.34);
  animation: np-pa-in 200ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
}
@keyframes np-pa-in {
  from { opacity: 0; transform: translateY(12px) scale(0.98); }
  to { opacity: 1; transform: none; }
}
.np-pa-sheet__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px 12px;
  border-bottom: 1px solid var(--np-line);
}
.np-pa-sheet__head h2 { margin: 0; font-size: 16px; font-weight: 600; }
.np-pa-sheet__close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 50%;
  background: var(--np-bg-soft);
  color: var(--np-muted);
  cursor: pointer;
}
.np-pa-sheet__close:hover { color: var(--np-text); background: var(--np-line); }
.np-pa-sheet__body { padding: 16px 18px 22px; }
.np-pa-sheet__body[hidden] { display: none !important; }
.np-pa-sheet__desc { margin: 0 0 14px; font-size: 13px; line-height: 1.7; color: var(--np-text-2); }

.np-pa__amounts { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.np-pa__amount {
  padding: 6px 14px;
  border: 1px solid var(--np-line);
  border-radius: 999px;
  background: var(--np-bg-soft);
  color: var(--np-text-2);
  font-size: 13px;
  cursor: pointer;
  transition: all var(--np-transition);
}
.np-pa__amount:hover { border-color: var(--np-primary); color: var(--np-primary); }
.np-pa__amount.is-active {
  border-color: #ff5c9a;
  background: rgba(255, 92, 154, 0.1);
  color: #ff5c9a;
  font-weight: 600;
}

.np-pa__pay-tabs { display: flex; gap: 8px; margin-bottom: 14px; }
.np-pa__pay-tab {
  flex: 1;
  padding: 8px 6px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: transparent;
  color: var(--np-text-2);
  font-size: 13px;
  cursor: pointer;
}
.np-pa__pay-tab.is-active {
  border-color: var(--np-primary);
  background: var(--np-primary-soft);
  color: var(--np-primary);
  font-weight: 600;
}
.np-pa__pay-pane[hidden] { display: none !important; }

.np-pa__qr {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 200px;
  height: 200px;
  max-width: 100%;
  margin: 0 auto;
  padding: 10px;
  background: #fff;
  border: 1px solid var(--np-line);
  border-radius: 10px;
}
.np-pa__qr svg { display: block; width: 100%; height: 100%; }
.np-pa__qr-img { display: block; max-width: 100%; max-height: 100%; object-fit: contain; }
.np-pa__qr-miss { font-size: 12px; color: var(--np-muted); text-align: center; padding: 12px; }
.np-pa__qr-tip { margin: 10px 0 0; text-align: center; font-size: 12px; color: var(--np-muted); }
.np-pa__thanks { margin: 14px 0 0; text-align: center; font-size: 13px; color: #ff5c9a; font-weight: 600; }
.np-pa__empty {
  padding: 18px;
  border: 1px dashed var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg-soft);
  color: var(--np-muted);
  font-size: 12.5px;
  line-height: 1.7;
  text-align: center;
}

.np-pa__share-qr { text-align: center; margin-bottom: 14px; }
.np-pa__share-qr .np-pa__qr { width: 172px; height: 172px; }
.np-pa__share-qr p { margin: 9px 0 0; font-size: 12px; color: var(--np-muted); }
.np-pa__share-link {
  overflow: hidden;
  padding: 9px 12px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg-soft);
  color: var(--np-text-2);
  font-size: 12px;
  text-align: center;
  white-space: nowrap;
  text-overflow: ellipsis;
  margin-bottom: 14px;
}
.np-pa__share-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.np-pa__share-btn {
  padding: 10px 4px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg-soft);
  color: var(--np-text-2);
  font-size: 12.5px;
  cursor: pointer;
  transition: all var(--np-transition);
}
.np-pa__share-btn:hover { border-color: var(--np-primary); color: var(--np-primary); transform: translateY(-1px); }

.np-pa__toast {
  position: fixed;
  left: 50%;
  bottom: 60px;
  z-index: 10000;
  max-width: min(86vw, 420px);
  padding: 10px 18px;
  border-radius: 999px;
  background: rgba(24, 28, 35, 0.94);
  color: #fff;
  font-size: 13px;
  text-align: center;
  box-shadow: 0 8px 26px rgba(0, 0, 0, 0.24);
  transform: translateX(-50%);
  animation: np-pa-toast-in 200ms ease-out both;
}
.np-pa__toast.is-out { opacity: 0; transition: opacity 200ms ease; }
@keyframes np-pa-toast-in {
  from { opacity: 0; transform: translate(-50%, 8px); }
  to { opacity: 1; transform: translateX(-50%); }
}

/* ---------- 用户中心「我的收藏」 ---------- */
.np-pa-favs__list { list-style: none; margin: 0; padding: 0; }
.np-pa-favs__item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--np-line);
}
.np-pa-favs__item:last-child { border-bottom: 0; }
.np-pa-favs__title {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--np-text);
  font-size: 14px;
  text-decoration: none;
}
.np-pa-favs__title:hover { color: var(--np-primary); }
.np-pa-favs__date { flex: 0 0 auto; font-size: 12px; color: var(--np-muted); }
.np-pa-favs__remove {
  flex: 0 0 auto;
  padding: 4px 10px;
  border: 1px solid var(--np-line);
  border-radius: 999px;
  background: transparent;
  color: var(--np-muted);
  font-size: 12px;
  cursor: pointer;
}
.np-pa-favs__remove:hover { border-color: var(--np-accent); color: var(--np-accent); }
.np-pa-favs__remove:disabled { opacity: 0.5; cursor: default; }
.np-pa-favs__empty { margin: 0; padding: 14px 0; font-size: 13px; color: var(--np-muted); line-height: 1.7; }

@media (max-width: 640px) {
  .np-pa__bar { padding: 14px 4px 8px; }
  .np-pa__act { gap: 5px; padding: 6px 2px 8px; }
  .np-pa__ico svg { width: 23px; height: 23px; }
  .np-pa__label { font-size: 12px; }
  .np-pa__count { font-size: 11px; }
  .np-pa__tip { font-size: 11px; padding-bottom: 13px; }
  .np-pa-sheet { align-items: flex-end; padding: 0; }
  .np-pa-sheet__panel {
    width: 100%;
    max-height: 88vh;
    border-radius: 16px 16px 0 0;
    animation: np-pa-up 220ms cubic-bezier(0.2, 0.8, 0.2, 1) both;
  }
  @keyframes np-pa-up {
    from { transform: translateY(100%); }
    to { transform: none; }
  }
  .np-pa__share-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .np-pa-favs__item { flex-wrap: wrap; gap: 6px 10px; }
  .np-pa-favs__title { flex-basis: 100%; white-space: normal; }
}

@media (prefers-reduced-motion: reduce) {
  .np-pa-sheet__panel, .np-pa__toast { animation: none; }
  .np-pa__act:hover, .np-pa__share-btn:hover { transform: none; }
}

/* ==========================================================================
   38. 1.8.50 电脑版快捷工具：常驻一竖排（子比式），翻译回到顶部
   ==========================================================================

   1.8.42 为了给电脑端加拖动，把面板改成 absolute + 独立圆形把手；1.8.43 又
   把桌面面板默认 display:none，点把手才展开。这次改回最初 29 章的做法：
   - 桌面（>=961px）一竖排常驻，不用点击展开，每枚按钮独立圆角 + hover 名称；
   - 拖动把手并入竖排第一格，做成同尺寸方形按钮，不再是分离的渐变圆钮；
   - 面板回到普通流、去掉毛玻璃与 overflow，hover 气泡不再被裁切；
   - 翻译从工具组拆到顶部导航栏右侧，菜单不再被侧边栏 overflow 裁切；
   - 手机端（<=960px）完全不变：一枚「工具」按钮点开展开，且面板里没有翻译。

   这里全部用「同特异性 + 后出现」覆盖 35 / 36 章，不动历史规则本身。
   ========================================================================== */

@media (min-width: 961px) {

  /* 面板常驻展开并回到普通流；外框交还给每一枚按钮 */
  .np-side-tools[data-np-drag="all"] .np-side-tools__body {
    position: static;
    display: flex !important;
    left: auto;
    right: auto;
    top: auto;
    bottom: auto;
    width: auto;
    min-width: 0;
    max-height: none;
    overflow: visible;
    padding: 0;
    gap: 8px;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }

  /* 拖到右侧 / 上半屏时的四象限定位在普通流里不再需要 */
  .np-side-tools[data-np-drag="all"].np-side-tools--at-right .np-side-tools__body,
  .np-side-tools[data-np-drag="all"].np-side-tools--right .np-side-tools__body,
  .np-side-tools[data-np-drag="all"].np-side-tools--drop-down .np-side-tools__body {
    left: auto;
    right: auto;
    top: auto;
    bottom: auto;
  }

  /* 工具按钮恢复 40px 独立卡片，与 29 章基础样式一致 */
  .np-side-tools[data-np-drag="all"] .np-side-tools .np-header__actions { gap: 8px; }
  .np-side-tools[data-np-drag="all"] .npm-toggle,
  .np-side-tools[data-np-drag="all"] .np-user-toggle,
  .np-side-tools[data-np-drag="all"] .np-cart-toggle,
  .np-side-tools[data-np-drag="all"] .np-search-toggle,
  .np-side-tools[data-np-drag="all"] .np-dark-toggle,
  .np-side-tools[data-np-drag="all"] .np-translate-toggle {
    width: 40px;
    height: 40px;
    border: 1px solid var(--np-line);
    border-radius: 10px;
    background: var(--np-bg);
  }
  .np-side-tools[data-np-drag="all"] .np-side-tools__backtop {
    width: 40px;
    height: 40px;
  }

  /* 拖动把手并入竖排：同尺寸方形卡片，不再是分离的紫色渐变圆按钮 */
  .np-side-tools[data-np-drag="all"] .np-side-tools__toggle {
    width: 40px;
    height: 40px;
    padding: 0;
    border: 1px solid var(--np-line);
    border-radius: 10px;
    background: var(--np-bg);
    color: var(--np-text-2);
    box-shadow: 0 2px 7px rgba(9, 14, 22, 0.08);
    cursor: grab;
  }
  .np-side-tools[data-np-drag="all"] .np-side-tools__toggle:hover {
    filter: none;
    border-color: var(--np-primary);
    color: var(--np-primary);
    background: var(--np-primary-soft);
  }
  .np-side-tools[data-np-drag="all"] .np-side-tools__toggle svg {
    width: 17px;
    height: 17px;
  }

  /* 常驻展开时九点格始终显示，不要切成关闭图标 */
  .np-side-tools[data-np-drag="all"] .np-side-tools__icon-open { display: block; }
  .np-side-tools[data-np-drag="all"] .np-side-tools__icon-close { display: none; }

  /* 拖动中整条轻微抬起，和手机端一致 */
  .np-side-tools[data-np-drag="all"].np-side-tools--dragging .np-side-tools__toggle {
    transform: scale(1.06);
  }
}

/* 顶部这枚翻译按钮与搜索 / 用户中心保持同一尺寸，下拉菜单贴着按钮展开 */
.np-header__actions--top .np-translate-wrap { position: relative; flex: none; }
.np-header__actions--top .np-translate-menu {
  top: calc(100% + 8px);
  right: 0;
  bottom: auto;
  left: auto;
  z-index: 90;
}


/* ==========================================================================
   39. 1.8.51 小工具位置（页面 × 位置）
   ==========================================================================
   20 个新区域共用一套输出结构：.np-wa 外层 + register_sidebar 的
   before_widget 外壳。顶部 / 底部是通栏，主内容上 / 下在内容列内竖排。
   首页模块小工具是 bare 输出（自带 <section class="np-module">），所以
   通栏位置里让它占满整行，其余窄卡片自动分栏。
   ========================================================================== */

.np-wa { margin: 0 0 20px; }
.np-wa:last-child { margin-bottom: 0; }

/* 通栏位置：窄卡片自动分栏，首页模块占整行 */
.np-wa--top,
.np-wa--bottom {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
  align-items: stretch;
  width: 100%;
}
.np-wa--top { margin: 0 0 22px; }
.np-wa--bottom { margin: 22px 0 0; }
.np-wa--top > *,
.np-wa--bottom > * { margin-bottom: 0; }
.np-wa--top > .np-module,
.np-wa--bottom > .np-module { grid-column: 1 / -1; }

/* 内容列内的上 / 中 / 下位置：竖排堆叠，去掉模块自带的 36px 下边距。
   1.8.72：新增「主内容」槽位（原来主题硬编码的默认文章列表区），让它和
   主内容上面 / 下面一样，与相邻内容之间留出 20px，解决「正文/列表/文章
   与主内容下面并在一起」的问题。空位置不占空间（输出时整块不存在）。 */
.np-wa--above { margin: 0 0 20px; }
.np-wa--main { margin: 20px 0; }
.np-wa--below { margin: 20px 0 20px; }
.np-wa--above > * + *,
.np-wa--main > * + *,
.np-wa--below > * + * { margin-top: 16px; }
.np-wa--above > .np-module,
.np-wa--main > .np-module,
.np-wa--below > .np-module,
.np-wa--above > .np-widget,
.np-wa--main > .np-widget,
.np-wa--below > .np-widget { margin-bottom: 0; }

@media (max-width: 720px) {
  .np-wa--top,
  .np-wa--bottom { grid-template-columns: 1fr; }
}

/* ==========================================================================
   40. 1.8.52 页面样式方案：方案结构 / 逐级覆盖 / 单篇设置
   --------------------------------------------------------------------------
   设计令牌（主色、圆角、容器宽度…）由 inc/style-presets.php 追加到内联 CSS，
   这里只写「不依赖变量的结构性规则」。所有选择器都带 np-* 前缀，默认方案
   （magazine / *-default）没有任何对应规则，升级后外观与 1.8.51 完全一致。
   ========================================================================== */

/* 40.1 单篇 / 方案级内容宽度（避开顶栏自己的 .np-container） */
body.np-width-full .np-container:not(.np-header__inner) { max-width: 100%; }
body.np-width-wide .np-container:not(.np-header__inner) { max-width: calc(var(--np-container) + 200px); }
body.np-width-narrow .np-container:not(.np-header__inner) { max-width: 720px; }

/* 40.2 文章标题的 4 种样式 */
body.np-title-center .np-single__header { text-align: center; }
body.np-title-center .np-single__title { font-size: clamp(26px, 3.4vw, 38px); }
body.np-title-center .np-single__meta { justify-content: center; }

body.np-title-plain .np-single { border: 0; box-shadow: none; background: transparent; padding: 8px 0 0; }
body.np-title-plain .np-single__title { font-weight: 600; letter-spacing: -.2px; }
body.np-title-plain .np-single > figure { display: none; }

body.np-title-cover .np-single { display: flex; flex-direction: column; padding-top: 0; overflow: hidden; }
body.np-title-cover .np-single > * { order: 3; }
body.np-title-cover .np-single > figure { order: 1; margin: 0 !important; }
body.np-title-cover .np-single > figure img { display: block; width: 100%; border-radius: 0 !important; }
body.np-title-cover .np-single__header {
  order: 2; position: relative; z-index: 2; margin-top: -96px;
  padding: 42px 28px 18px; border-radius: 0;
  background: linear-gradient(transparent, rgba(0, 0, 0, .74)); color: #fff;
}
body.np-title-cover .np-single__title { color: #fff; text-shadow: 0 2px 14px rgba(0, 0, 0, .4); }
body.np-title-cover .np-single__meta { color: rgba(255, 255, 255, .86); border-bottom-color: rgba(255, 255, 255, .2); }
body.np-title-cover .np-single__meta a { color: #fff; }
body.np-title-cover .np-entry { padding: 0 28px; }

/* 40.3 文章列表的补充显示模式
   list / grid / card 由 content-archive.php 的骨架决定，这里只加微调；
   multi / seamless / auto / text 在无侧栏时由解析层自动退回 list，避免错版。 */
body.np-list-text .np-post-grid { grid-template-columns: 1fr !important; }
body.np-list-text .np-card { border: 0; border-bottom: 1px solid var(--np-line); border-radius: 0; box-shadow: none; background: transparent; }
body.np-list-text .np-card__title { font-size: 19px; font-weight: 600; }
body.np-list-text .np-card__body { padding: 6px 0 16px; }

body.np-list-multi .np-post-item { display: block; }
body.np-list-multi .np-post-item__thumb { width: 100%; height: auto; margin: 0 0 12px; }
body.np-list-multi .np-post-item__thumb img { width: 100%; height: 160px; object-fit: cover; }

body.np-list-seamless .np-post-item { border: 0; border-bottom: 1px solid var(--np-line); border-radius: 0; box-shadow: none; background: transparent; }
body.np-list-seamless .np-post-item:last-child { border-bottom: 0; }

body.np-list-auto .np-post-item__thumb { width: 132px; }
body.np-list-auto .np-post-item__body { padding-left: 4px; }
body.np-list-auto .np-post-item:not(:has(img)) .np-post-item__thumb { display: none; }

/* 40.4 方案专属结构：1.8.54 起统一迁至文末第 42 章。
   原先这里只有 20 行占位规则，三套方案的卡片 / 顶栏 / 小工具仍是默认外观；
   且 shop 把主色按钮文字设成主色，与橙色按钮底同色，导致按钮文字不可见。
   完整视觉见「42. 1.8.54 三套方案视觉重做」，此处保留章节编号占位。 */

/* 40.5 前台「页面设置」浮标：1.8.58 已移除。
   原先这个 fixed 胶囊按钮的显示条件是 is_singular() + 管理员，
   但主题 14 个功能页模板也都是 page，管理员浏览用户中心 / VIP 会员时
   同样会出现，且在手机上压住底部导航右侧两项。单篇样式覆盖改回
   后台编辑文章时的「页面样式」meta box 操作，方案能力一行未删。 */

@media (max-width: 720px) {
  body.np-title-cover .np-single__header { margin-top: -64px; padding: 28px 16px 14px; }
}



/* ==========================================================================
   41. 1.8.53 小工具适用范围与双端适配
   --------------------------------------------------------------------------
   三件事：
   (1) 每个小工具输出 data-np-scope（side 侧栏 / wide 全宽 / both 通用）、
       data-np-device、data-np-cols、data-np-cols-m，以及 --np-w-cols 变量；
   (2) 全宽模块误投到侧栏 / 内容列时自动降成单列，不撑破容器；
   (3) 手机端统一降列，侧栏按全站策略堆叠 / 隐藏，并给 12 个新小工具
       一套移动优先的样式。默认（不配置）就是电脑 + 手机都好看。
   body 类：np-ws-stack|hide|keep、np-wm-auto|1|2、np-ws-sticky。
   ========================================================================== */

/* 41.1 列数：单实例覆盖 > 全站默认 > 结构默认 */
.np-wx-grid {
  display: grid;
  grid-template-columns: repeat(var(--np-wx-cols, 4), minmax(0, 1fr));
  gap: 12px;
}
.np-wa__widget[data-np-cols="1"] { --np-wx-cols: 1; --np-cols: 1; }
.np-wa__widget[data-np-cols="2"] { --np-wx-cols: 2; --np-cols: 2; }
.np-wa__widget[data-np-cols="3"] { --np-wx-cols: 3; --np-cols: 3; }
.np-wa__widget[data-np-cols="4"] { --np-wx-cols: 4; --np-cols: 4; }

/* 全宽模块在通栏位置必须独占整行：1.8.51 只给 bare 输出的 .np-module
   加了 grid-column:1/-1，常规外壳的 wide 小工具会并排挤成半宽。 */
.np-wa--top > .np-wa__widget[data-np-scope="wide"],
.np-wa--bottom > .np-wa__widget[data-np-scope="wide"] {
  grid-column: 1 / -1;
}

/* 41.2 全宽模块被投进窄容器（侧栏 / 主内容上 / 下）：自动单列降级 */
.np-wa[data-np-wide="0"] .np-wa__widget[data-np-scope="wide"],
[data-np-slot-scope="side"] .np-wa__widget[data-np-scope="wide"],
.np-sidebar-col .np-wa__widget[data-np-scope="wide"] {
  --np-cols: 1;
  --np-wx-cols: 1;
}
.np-wa[data-np-wide="0"] .np-wa__widget[data-np-scope="wide"] .np-post-grid,
.np-wa[data-np-wide="0"] .np-wa__widget[data-np-scope="wide"] .np-video-grid,
.np-wa[data-np-wide="0"] .np-wa__widget[data-np-scope="wide"] .np-stats,
.np-wa[data-np-wide="0"] .np-wa__widget[data-np-scope="wide"] .np-cats,
.np-sidebar-col .np-wa__widget[data-np-scope="wide"] .np-post-grid,
.np-sidebar-col .np-wa__widget[data-np-scope="wide"] .np-video-grid,
.np-sidebar-col .np-wa__widget[data-np-scope="wide"] .np-stats {
  grid-template-columns: 1fr !important;
}
.np-wa[data-np-wide="0"] .np-wa__widget[data-np-scope="wide"] .np-slider,
.np-sidebar-col .np-wa__widget[data-np-scope="wide"] .np-slider {
  height: 200px;
}
.np-wa[data-np-wide="0"] .np-wa__widget[data-np-scope="wide"] .np-module__title,
.np-sidebar-col .np-wa__widget[data-np-scope="wide"] .np-module__title {
  font-size: 17px;
}
/* 侧栏里放侧栏组件：本来就是窄卡，去掉模块级的大外边距 */
.np-sidebar-col .np-wa__widget .np-module { margin-bottom: 0; }

/* 41.3 电脑端：侧栏随动（仅在侧栏比正文短时生效） */
@media (min-width: 961px) {
  body.np-ws-sticky .np-sidebar-col {
    position: sticky;
    top: 84px;
    align-self: start;
  }
}

/* 41.4 手机端统一适配 */
@media (max-width: 960px) {
  /* 子比式策略：手机端彻底隐藏侧栏 */
  body.np-ws-hide .np-sidebar-col { display: none !important; }
  /* 默认策略：侧栏移到正文下方、单列铺满，内容一条不丢 */
  body.np-ws-stack .np-layout,
  body.np-ws-stack .np-layout--left { grid-template-columns: minmax(0, 1fr); }
  body.np-ws-stack .np-layout--left .np-content,
  body.np-ws-stack .np-layout--left .np-sidebar-col { order: initial; }
  body.np-ws-stack .np-sidebar-col { margin-top: 22px; }
  body.np-ws-stack .np-sidebar-col .np-widget { margin-bottom: 14px; }
  /* keep：保持原样，什么都不改 */
}

@media (max-width: 768px) {
  /* 前端兜底：服务端已按 wp_is_mobile 过滤，这里再保证缓存页面也正确 */
  .np-wa__widget[data-np-device="desktop"] { display: none !important; }
  .np-wa__widget[data-np-device="mobile"] { display: block; }
  .np-wa__widget[data-np-device="compact"] { font-size: 13px; }
  .np-wa__widget[data-np-device="compact"] .np-widget__title { font-size: 15px; padding: 10px 12px; }

  /* 新小工具：默认 2 列小卡；全站设 1 列则一律 1 列 */
  .np-wx-grid { grid-template-columns: repeat(var(--np-wx-cols-m, 2), minmax(0, 1fr)) !important; gap: 10px; }
  body.np-wm-1 .np-wx-grid { --np-wx-cols-m: 1; }
  body.np-wm-2 .np-wx-grid { --np-wx-cols-m: 2; }
  .np-wa__widget[data-np-cols-m="1"] { --np-wx-cols-m: 1; }
  .np-wa__widget[data-np-cols-m="2"] { --np-wx-cols-m: 2; }
  /* 大卡（图标卡 / 网址导航）手机端最多 2 列，避免文字挤压 */
  .np-wx-icons.np-wx-grid,
  .np-wx-nav.np-wx-grid { --np-wx-cols-m: 2; }

  /* 已有模块：手机端统一降到 1 列（全站可设 2 列，单实例可再覆盖） */
  .np-wa__widget { --np-cols-mobile: 1; }
  body.np-wm-2 .np-wa__widget { --np-cols-mobile: 2; }
  .np-wa__widget[data-np-cols-m="1"] { --np-cols-mobile: 1; }
  .np-wa__widget[data-np-cols-m="2"] { --np-cols-mobile: 2; }
  .np-wa__widget[data-np-scope] .np-post-grid,
  .np-wa__widget[data-np-scope] .np-video-grid,
  .np-wa__widget[data-np-scope] .np-stats {
    grid-template-columns: repeat(var(--np-cols-mobile, 1), minmax(0, 1fr)) !important;
  }
  .np-wa__widget[data-np-scope] .np-slider { height: auto; aspect-ratio: 16 / 9; }
  .np-wa--top,
  .np-wa--bottom { grid-template-columns: 1fr; }
  .np-wa--mobile { display: block; margin: 0 0 20px; }

  /* 手机端所有小工具内边距收紧，标题不换行溢出 */
  .np-wa__widget .np-widget__title { font-size: 15px; }
  .np-wa__widget .np-module__head { margin-bottom: 12px; }
  .np-wa__widget .np-module__title { font-size: 17px; }
}
@media (min-width: 769px) {
  .np-wa--mobile { display: none; }
}

/* 41.5 新小工具：图标 / 链接 / 导航 ------------------------------- */
.np-wx-empty { padding: 14px; color: #8b939e; font-size: 13px; text-align: center; }
.np-wx-icon { display: inline-flex; align-items: center; justify-content: center; width: 38px; height: 38px; border-radius: 10px; background: var(--np-primary-soft, #eef4fb); flex: 0 0 auto; }
.np-wx-icon__dot { width: 9px; height: 9px; border-radius: 50%; background: var(--np-primary, #2271b1); }
.np-wx-icon__emoji { font-size: 20px; line-height: 1; }
.np-wx-icon__font { font-size: 20px; width: auto; height: auto; }
.np-wx-icon__img { width: 100%; height: 100%; object-fit: contain; border-radius: 8px; }

.np-wx-icons__card {
  display: flex; flex-direction: column; gap: 8px; padding: 18px 16px;
  border: 1px solid var(--np-border, #e4e7ec); border-radius: var(--np-radius, 10px);
  background: var(--np-card, #fff); text-decoration: none; color: inherit;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.np-wx-icons__card:hover { transform: translateY(-2px); box-shadow: 0 8px 22px rgba(20,40,80,.09); border-color: var(--np-primary, #2271b1); }
.np-wx-icons__icon { width: 42px; height: 42px; }
.np-wx-icons__title { font-size: 15px; font-weight: 700; color: var(--np-text, #252b33); }
.np-wx-icons__desc { font-size: 12px; line-height: 1.7; color: var(--np-muted, #7a828d); }
.np-wx-icons--plain .np-wx-icons__card { border: 0; background: transparent; padding: 8px 4px; box-shadow: none; }
.np-wx-icons--horizon .np-wx-icons__card { flex-direction: row; align-items: center; text-align: left; }
.np-wx-icons--horizon.np-wx-grid { grid-template-columns: 1fr; }
.np-wx-icons--blue .np-wx-icon { background: #e7f0fb; color: #1a6fb5; }
.np-wx-icons--green .np-wx-icon { background: #e8f4ec; color: #2f7d52; }
.np-wx-icons--orange .np-wx-icon { background: #fdf0e2; color: #b26a00; }
.np-wx-icons--purple .np-wx-icon { background: #f0eafa; color: #7048b6; }

.np-wx-nav__card {
  display: flex; align-items: center; gap: 10px; padding: 12px;
  border: 1px solid var(--np-border, #e4e7ec); border-radius: var(--np-radius, 10px);
  background: var(--np-card, #fff); text-decoration: none; color: inherit; min-width: 0;
  transition: border-color .2s ease, transform .2s ease;
}
.np-wx-nav__card:hover { border-color: var(--np-primary, #2271b1); transform: translateY(-2px); }
.np-wx-nav__icon { width: 34px; height: 34px; }
.np-wx-nav__body { display: flex; flex-direction: column; min-width: 0; }
.np-wx-nav__body strong { font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.np-wx-nav__body small { font-size: 11px; color: var(--np-muted, #7a828d); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.np-wx-links { list-style: none; margin: 0; padding: 0; }
.np-wx-links--grid.np-wx-links { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 8px; }
.np-wx-links__a { display: flex; align-items: center; gap: 10px; padding: 10px; border: 1px solid var(--np-border, #e4e7ec); border-radius: 8px; text-decoration: none; color: inherit; }
.np-wx-links__a:hover { border-color: var(--np-primary, #2271b1); }
.np-wx-links__text { display: flex; flex-direction: column; min-width: 0; }
.np-wx-links__text strong { font-size: 13px; }
.np-wx-links__text small { font-size: 11px; color: var(--np-muted, #7a828d); }
.np-wx-links--list .np-wx-links__item + .np-wx-links__item { margin-top: 6px; }
.np-wx-links--text { display: flex; flex-wrap: wrap; gap: 6px 14px; }
.np-wx-links--text .np-wx-links__a { border: 0; padding: 2px 0; background: none; }
.np-wx-links--text .np-wx-icon { display: none; }
.np-wx-links--text .np-wx-links__text small { display: none; }

/* 41.6 新小工具：标题按钮 / 间距 / 快讯 --------------------------- */
.np-wx-heading { padding: 6px 0 10px; }
.np-wx-heading--center { text-align: center; }
.np-wx-heading--right { text-align: right; }
.np-wx-heading__main { margin: 0 0 8px; font-size: 26px; line-height: 1.35; font-weight: 800; color: var(--np-text, #252b33); }
.np-wx-heading__sub { margin: 0 0 16px; font-size: 14px; color: var(--np-muted, #7a828d); }
.np-wx-heading__btns { display: flex; flex-wrap: wrap; gap: 10px; }
.np-wx-heading--center .np-wx-heading__btns { justify-content: center; }
.np-wx-heading--right .np-wx-heading__btns { justify-content: flex-end; }
.np-wx-btn { display: inline-flex; align-items: center; justify-content: center; padding: 9px 20px; border-radius: 8px; font-size: 13px; font-weight: 600; text-decoration: none; border: 1px solid transparent; }
.np-wx-btn--primary { background: var(--np-primary, #2271b1); color: #fff; }
.np-wx-btn--primary:hover { filter: brightness(1.08); color: #fff; }
.np-wx-btn--ghost { border-color: var(--np-border, #d8dde4); color: var(--np-text, #252b33); background: transparent; }
.np-wx-btn--ghost:hover { border-color: var(--np-primary, #2271b1); }
.np-wx-btn--link { padding: 9px 4px; color: var(--np-primary, #2271b1); }
@media (max-width: 768px) { .np-wx-heading__main { font-size: 21px; } .np-wx-heading__btns { gap: 8px; } .np-wx-btn { flex: 1 1 auto; } }

.np-wx-spacer { height: var(--np-wx-h, 24px); }
.np-wx-spacer--line { border-top: 1px dashed var(--np-border, #e0e4ea); }
@media (max-width: 768px) { .np-wx-spacer { height: var(--np-wx-hm, 12px); } }

.np-wx-flash { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border: 1px solid var(--np-border, #e4e7ec); border-radius: 8px; background: var(--np-card, #fff); overflow: hidden; }
.np-wx-flash__badge { flex: 0 0 auto; padding: 3px 9px; border-radius: 5px; font-size: 11px; font-weight: 700; color: #fff; background: var(--np-accent, #d63638); }
.np-wx-flash__viewport { flex: 1 1 auto; height: 24px; overflow: hidden; min-width: 0; }
.np-wx-flash__track { list-style: none; margin: 0; padding: 0; }
.np-wx-flash__item { height: 24px; line-height: 24px; font-size: 13px; color: var(--np-text, #252b33); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.np-wx-flash__item a { color: inherit; text-decoration: none; }
.np-wx-flash__item a:hover { color: var(--np-primary, #2271b1); }
.np-wx-flash--scroll .np-wx-flash__track { animation: np-wx-flash-run var(--np-wx-speed, 12s) linear infinite; }
.np-wx-flash:hover .np-wx-flash__track { animation-play-state: paused; }
@keyframes np-wx-flash-run { from { transform: translateY(0); } to { transform: translateY(-100%); } }
@media (prefers-reduced-motion: reduce) { .np-wx-flash--scroll .np-wx-flash__track { animation: none; } .np-wx-flash__viewport { height: auto; } .np-wx-flash__item { height: auto; line-height: 1.8; } }

/* 41.7 新小工具：目录树 / 评论 / TAB / 社交 / 统计 ---------------- */
.np-wx-toc { font-size: 13px; }
.np-wx-toc--sticky { position: sticky; top: 84px; }
.np-wx-toc__toggle { display: none; width: 100%; padding: 8px 0; border: 0; background: none; font-size: 14px; font-weight: 700; text-align: left; color: var(--np-text, #252b33); cursor: pointer; }
.np-wx-toc__caret { float: right; width: 8px; height: 8px; margin-top: 5px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg); transition: transform .2s ease; }
.np-wx-toc.is-collapsed .np-wx-toc__caret { transform: rotate(-45deg); }
.np-wx-toc__list { list-style: none; margin: 0; padding: 0 0 0 12px; border-left: 2px solid var(--np-border, #e4e7ec); }
.np-wx-toc.is-collapsed .np-wx-toc__list { display: none; }
.np-wx-toc__item { margin: 0; line-height: 1.9; }
.np-wx-toc__item--h3 { padding-left: 12px; font-size: 12px; }
.np-wx-toc__item a { display: block; color: var(--np-muted, #6b7480); text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.np-wx-toc__item a:hover, .np-wx-toc__item a.is-current { color: var(--np-primary, #2271b1); font-weight: 600; }
@media (max-width: 768px) { .np-wx-toc--sticky { position: static; } .np-wx-toc--collapsible .np-wx-toc__toggle { display: block; } .np-wx-toc--collapsible .np-wx-toc__list { display: none; } .np-wx-toc--collapsible:not(.is-collapsed) .np-wx-toc__list { display: none; } }

.np-wx-comments { list-style: none; margin: 0; padding: 0; }
.np-wx-comments__item { display: flex; gap: 10px; padding: 10px 0; border-bottom: 1px dashed var(--np-border, #eceef2); }
.np-wx-comments__item:last-child { border-bottom: 0; }
.np-wx-comments__avatar { flex: 0 0 36px; }
.np-wx-comments__avatar img { border-radius: 50%; width: 36px; height: 36px; }
.np-wx-comments__body { min-width: 0; flex: 1; }
.np-wx-comments__meta { display: flex; justify-content: space-between; gap: 8px; font-size: 12px; }
.np-wx-comments__meta strong { font-weight: 600; }
.np-wx-comments__meta span { color: var(--np-muted, #9aa1ab); }
.np-wx-comments__post { display: block; font-size: 13px; color: var(--np-text, #252b33); text-decoration: none; margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.np-wx-comments__post:hover { color: var(--np-primary, #2271b1); }
.np-wx-comments__text { margin: 3px 0 0; font-size: 12px; line-height: 1.6; color: var(--np-muted, #7a828d); }

.np-wx-tabs__radio { position: absolute; opacity: 0; pointer-events: none; }
.np-wx-tabs__nav { display: flex; gap: 4px; border-bottom: 1px solid var(--np-border, #e4e7ec); overflow-x: auto; scrollbar-width: none; }
.np-wx-tabs__nav::-webkit-scrollbar { display: none; }
.np-wx-tabs__label { flex: 0 0 auto; padding: 8px 16px; font-size: 13px; font-weight: 600; color: var(--np-muted, #7a828d); cursor: pointer; border-bottom: 2px solid transparent; white-space: nowrap; }
.np-wx-tabs__label:hover { color: var(--np-primary, #2271b1); }
.np-wx-tabs__panels { padding-top: 12px; }
.np-wx-tabs__panel { display: none; }
.np-wx-tabs__radio:nth-of-type(1):checked ~ .np-wx-tabs__panels .np-wx-tabs__panel[data-np-tab="0"],
.np-wx-tabs__radio:nth-of-type(2):checked ~ .np-wx-tabs__panels .np-wx-tabs__panel[data-np-tab="1"],
.np-wx-tabs__radio:nth-of-type(3):checked ~ .np-wx-tabs__panels .np-wx-tabs__panel[data-np-tab="2"],
.np-wx-tabs__radio:nth-of-type(4):checked ~ .np-wx-tabs__panels .np-wx-tabs__panel[data-np-tab="3"] { display: block; }
.np-wx-tabs__radio:nth-of-type(1):checked ~ .np-wx-tabs__nav .np-wx-tabs__label:nth-of-type(1),
.np-wx-tabs__radio:nth-of-type(2):checked ~ .np-wx-tabs__nav .np-wx-tabs__label:nth-of-type(2),
.np-wx-tabs__radio:nth-of-type(3):checked ~ .np-wx-tabs__nav .np-wx-tabs__label:nth-of-type(3),
.np-wx-tabs__radio:nth-of-type(4):checked ~ .np-wx-tabs__nav .np-wx-tabs__label:nth-of-type(4) { color: var(--np-primary, #2271b1); border-bottom-color: var(--np-primary, #2271b1); }
.np-wx-tabs__list { list-style: none; margin: 0; padding: 0; }
.np-wx-tabs__item { display: flex; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px dashed var(--np-border, #eceef2); }
.np-wx-tabs__item:last-child { border-bottom: 0; }
.np-wx-tabs__thumb { flex: 0 0 54px; }
.np-wx-tabs__thumb img { width: 54px; height: 42px; object-fit: cover; border-radius: 6px; }
.np-wx-tabs__body { display: flex; justify-content: space-between; gap: 8px; min-width: 0; flex: 1; }
.np-wx-tabs__title { font-size: 13px; color: var(--np-text, #252b33); text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.np-wx-tabs__title:hover { color: var(--np-primary, #2271b1); }
.np-wx-tabs__date { flex: 0 0 auto; font-size: 11px; color: var(--np-muted, #9aa1ab); }

.np-wx-social { text-align: center; }
.np-wx-social__qr { margin: 0 auto 10px; }
.np-wx-social__qr img { display: block; width: 132px; height: 132px; margin: 0 auto; object-fit: contain; border: 1px solid var(--np-border, #e4e7ec); border-radius: 8px; padding: 6px; background: #fff; }
.np-wx-social__qr span { display: block; margin-top: 6px; font-size: 12px; color: var(--np-muted, #7a828d); }
.np-wx-social__desc { margin: 0 0 12px; font-size: 12px; line-height: 1.7; color: var(--np-muted, #7a828d); }
.np-wx-social__links { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.np-wx-social__links a { display: inline-flex; align-items: center; gap: 5px; padding: 6px 10px; border: 1px solid var(--np-border, #e4e7ec); border-radius: 7px; font-size: 12px; color: var(--np-text, #252b33); text-decoration: none; }
.np-wx-social__links a:hover { border-color: var(--np-primary, #2271b1); }
.np-wx-social__ico { font-size: 14px; }

.np-wx-stats { --np-wx-cols: 4; }
.np-wx-stats--inline.np-wx-grid { grid-template-columns: repeat(var(--np-wx-cols, 4), minmax(0,1fr)); }
.np-wx-stats__cell { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 12px 6px; border-radius: 8px; background: var(--np-soft, #f6f8fa); }
.np-wx-stats__cell strong { font-size: 20px; font-weight: 800; color: var(--np-primary, #2271b1); line-height: 1.2; }
.np-wx-stats__cell span { font-size: 11px; color: var(--np-muted, #7a828d); }

.np-wx-html { line-height: 1.8; overflow-x: auto; }
.np-wx-html img { max-width: 100%; height: auto; }
.np-wx-html--flush { margin: -14px; }

/* 41.8 手机端专用区域：PC 不输出（PHP 已拦，这里再兜一层） */
.np-wa--mobile { margin: 0 0 20px; }
.np-wa--mobile .np-widget { margin-bottom: 12px; }


/* ==========================================================================
   42. 1.8.54 三套方案视觉重做
   --------------------------------------------------------------------------
   1.8.52 的 cards / reading / shop 只改了主色与 20 行结构样式，卡片、顶栏、
   模块、小工具、文章页仍是默认外观，看起来像「换了个颜色」而不是换了气质。
   本章为三套方案各补一整套设计语言：令牌与氛围 -> 顶栏导航 -> 模块与网格
   -> 卡片 / 列表 -> 小工具与页脚 -> 文章页与互动条 -> 暗色 -> 响应式。

   约定：
   - 所有规则以 body.np-preset-* 开头，magazine / *-default 零影响，旧站点
     升级后外观逐像素不变；
   - 只改外观（颜色 / 圆角 / 阴影 / 间距 / 字排 / 背景），不改 DOM 与布局结构；
   - 方案私有变量统一用 --sp-*，避免与 newspress_style_css() 内联输出的
     --np-* 变量发生层叠冲突；
   - 手机端三档降列（1100 / 900 / 560），缩内边距、去装饰、保证不横向溢出；
   - 暗色用 body.np-dark.np-preset-*（更高特异性）单独覆盖；
   - 尊重 prefers-reduced-motion。
   ========================================================================== */

/* ==========================================================================
   42.0 公共：让方案列数真正由令牌驱动
   --------------------------------------------------------------------------
   主题在 960px / 640px 两个断点里直接改 .np-post-grid 的
   grid-template-columns（分别 2 列 / 1 列），会盖掉方案只设 --np-cols 的
   写法，表现为「方案说 3 列，平板手机却按主题默认排」。这里用更高特异性
   把列数收回到变量：三套方案在任意宽度都按各自解析出的列数排布，
   同时不影响 1.8.53 小工具内带 !important 的双端列数控制。
   ========================================================================== */
body.np-preset-cards .np-post-grid,
body.np-preset-reading .np-post-grid,
body.np-preset-shop .np-post-grid {
  grid-template-columns: repeat(var(--np-cols, 3), minmax(0, 1fr));
}

/* 42.0.1 深色主色兜底：hover 不回退到资讯杂志的蓝色 */
body.np-preset-cards   { --np-primary-dark: #5644c9; }
body.np-preset-reading { --np-primary-dark: #245340; }
body.np-preset-shop    { --np-primary-dark: #c2461d; }

/* ==========================================================================
   42.1 卡片社区：轻盈、有大圆角与柔光，像内容社区的卡片瀑布
   ========================================================================== */

/* A. 令牌与页面氛围 */
body.np-preset-cards {
  --sp-ink: #241f3d;
  --sp-sub: #6d668c;
  --sp-line: #ebe7fa;
  --sp-surface: #ffffff;
  --sp-soft: #f2efff;
  --sp-brand: #6d5ce7;
  --sp-brand2: #a78bfa;
  --sp-shadow: 0 2px 6px rgba(60, 45, 130, .05), 0 14px 34px rgba(80, 60, 170, .09);
  --sp-shadow-hi: 0 6px 14px rgba(60, 45, 130, .09), 0 22px 52px rgba(80, 60, 170, .18);
  --sp-radius: 18px;
  color: var(--sp-ink);
  background-color: #f7f6ff;
  background-image:
    radial-gradient(920px 460px at 8% -10%, rgba(109, 92, 231, .14), transparent 70%),
    radial-gradient(780px 420px at 96% 2%, rgba(167, 139, 250, .13), transparent 72%);
  background-attachment: fixed;
  background-repeat: no-repeat;
}
body.np-preset-cards .np-main { padding-top: 30px; }

/* B. 顶栏与导航：玻璃拟态渐变 + 胶囊导航 */
body.np-preset-cards .np-header {
  background: linear-gradient(105deg, #6d5ce7 0%, #7d6ae9 46%, #9b83f2 100%);
  border-bottom: 1px solid rgba(255, 255, 255, .18);
  box-shadow: 0 6px 24px rgba(88, 68, 190, .18);
}
body.np-preset-cards .np-header.is-sticky {
  background: linear-gradient(105deg, rgba(109, 92, 231, .94), rgba(155, 131, 242, .94));
  backdrop-filter: saturate(180%) blur(16px);
}
body.np-preset-cards .np-header__inner { height: 68px; }
body.np-preset-cards .np-brand__name {
  color: #fff; font-weight: 800; letter-spacing: -.5px; font-size: 21px;
}
body.np-preset-cards .np-brand__name em { color: #ffe9a8; }
body.np-preset-cards .np-brand::before {
  content: ''; width: 26px; height: 26px; border-radius: 9px;
  background: linear-gradient(135deg, #fff, #ffe9a8);
  box-shadow: 0 3px 10px rgba(0, 0, 0, .12);
  order: 2;
}
body.np-preset-cards .np-search-toggle,
body.np-preset-cards .np-dark-toggle,
body.np-preset-cards .np-translate-toggle {
  width: 36px; height: 36px; border-radius: 12px;
  border-color: rgba(255, 255, 255, .3);
  background: rgba(255, 255, 255, .14); color: #fff;
}
body.np-preset-cards .np-search-toggle:hover,
body.np-preset-cards .np-dark-toggle:hover,
body.np-preset-cards .np-translate-toggle:hover {
  background: rgba(255, 255, 255, .28); border-color: rgba(255, 255, 255, .7); color: #fff;
}
body.np-preset-cards .np-header__search input,
body.np-preset-cards .np-header__search input:focus {
  background: rgba(255, 255, 255, .16); border-color: rgba(255, 255, 255, .26);
  color: #fff; border-radius: 999px;
}
body.np-preset-cards .np-header__search input::placeholder { color: rgba(255, 255, 255, .7); }
body.np-preset-cards .np-btn--primary,
body.np-preset-cards .np-header .np-btn--primary {
  background: #fff; border-color: #fff; color: var(--sp-brand);
  border-radius: 999px; padding: 0 20px; font-weight: 700;
  box-shadow: 0 3px 12px rgba(40, 28, 100, .16);
}
body.np-preset-cards .np-btn--primary:hover {
  background: #fff4cf; border-color: #fff4cf; color: #5644c9;
}

/* C. 模块标题与网格 */
body.np-preset-cards .np-module { margin-bottom: 34px; }
body.np-preset-cards .np-module__head {
  border-bottom: 0; padding-bottom: 0; margin-bottom: 18px;
}
body.np-preset-cards .np-module__title {
  font-size: 21px; font-weight: 800; letter-spacing: -.4px; color: var(--sp-ink);
  gap: 10px;
}
body.np-preset-cards .np-module__title::before {
  width: 12px; height: 12px; border-radius: 4px;
  background: linear-gradient(135deg, var(--sp-brand), var(--sp-brand2));
  box-shadow: 0 3px 10px rgba(109, 92, 231, .35);
}
body.np-preset-cards .np-module__more {
  color: var(--sp-brand); font-weight: 600; font-size: 13px;
  padding: 6px 13px; border-radius: 999px; background: var(--sp-soft);
}
body.np-preset-cards .np-module__more:hover { color: #fff; background: var(--sp-brand); }
body.np-preset-cards .np-post-grid { gap: 22px; }
body.np-preset-cards .np-breadcrumb,
body.np-preset-cards .np-crumb {
  color: var(--sp-sub); font-size: 12.5px; margin-bottom: 18px;
}
body.np-preset-cards .np-breadcrumb b,
body.np-preset-cards .np-crumb b { color: var(--sp-brand); }

/* D. 卡片：无边框、大圆角、柔阴影、悬浮上浮 */
body.np-preset-cards .np-card {
  border: 0; border-radius: var(--sp-radius);
  background: var(--sp-surface); box-shadow: var(--sp-shadow);
  transition: transform 260ms cubic-bezier(.2, .8, .2, 1), box-shadow 260ms ease;
}
body.np-preset-cards .np-card:hover {
  transform: translateY(-6px); box-shadow: var(--sp-shadow-hi); border-color: transparent;
}
body.np-preset-cards .np-card__thumb { aspect-ratio: 16 / 10; }
body.np-preset-cards .np-card__thumb::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, transparent 62%, rgba(36, 31, 61, .16));
}
body.np-preset-cards .np-card__thumb::before {
  content: ''; position: absolute; z-index: 2; left: 12px; top: 12px;
  width: 8px; height: 8px; border-radius: 50%;
  background: #fff; box-shadow: 14px 0 0 rgba(255, 255, 255, .7), 28px 0 0 rgba(255, 255, 255, .42);
}
body.np-preset-cards .np-card__body { padding: 16px 18px 18px; }
body.np-preset-cards .np-card__title {
  font-size: 16px; font-weight: 700; line-height: 1.5; letter-spacing: -.2px;
  margin-bottom: 9px;
}
body.np-preset-cards .np-card__title a { color: var(--sp-ink); }
body.np-preset-cards .np-card:hover .np-card__title a { color: var(--sp-brand); }
body.np-preset-cards .np-card__body > p { color: var(--sp-sub); line-height: 1.7; }
body.np-preset-cards .np-post-meta {
  color: var(--sp-sub); font-size: 12px; gap: 12px;
  padding-top: 11px; margin-top: 4px;
  border-top: 1px solid var(--sp-line);
}
body.np-preset-cards .np-post-meta::before {
  content: ''; width: 20px; height: 20px; border-radius: 50%;
  background: linear-gradient(135deg, var(--sp-brand), var(--sp-brand2));
  box-shadow: inset 0 0 0 2px #fff; flex: none;
}
body.np-preset-cards .np-post-item {
  border-bottom-color: var(--sp-line); padding-bottom: 20px; gap: 20px;
}
body.np-preset-cards .np-post-item__thumb { border-radius: 14px; }
body.np-preset-cards .np-post-item__title { font-weight: 700; letter-spacing: -.2px; }

/* E. 小工具、页脚、快捷工具 */
body.np-preset-cards .np-widget {
  border: 0; border-radius: var(--sp-radius);
  background: var(--sp-surface); box-shadow: var(--sp-shadow); padding: 20px;
}
body.np-preset-cards .np-widget__title {
  border-bottom-color: var(--sp-line); font-weight: 800; letter-spacing: -.2px;
}
body.np-preset-cards .np-widget__title::before {
  width: 8px; height: 8px; border-radius: 3px;
  background: linear-gradient(135deg, var(--sp-brand), var(--sp-brand2));
}
body.np-preset-cards .np-footer {
  border-top: 0; background: #f0edff; color: var(--sp-sub);
  box-shadow: inset 0 1px 0 rgba(109, 92, 231, .12);
}
body.np-preset-cards .np-side-tools[data-np-drag="all"] .np-side-tools__body {
  border-radius: 16px; box-shadow: var(--sp-shadow);
}

/* F. 文章页与互动条 */
body.np-preset-cards .np-single {
  border: 0; border-radius: var(--sp-radius); padding: 34px 38px;
  background: var(--sp-surface); box-shadow: var(--sp-shadow);
}
body.np-preset-cards .np-single__title {
  font-size: clamp(27px, 3.4vw, 38px); font-weight: 800; letter-spacing: -.7px; line-height: 1.35;
}
body.np-preset-cards .np-single__meta { border-bottom-color: var(--sp-line); }
body.np-preset-cards .np-single__cats a {
  border-radius: 999px; padding: 3px 12px; background: var(--sp-soft); color: var(--sp-brand);
}
body.np-preset-cards .np-entry { font-size: 16px; line-height: 1.92; }
body.np-preset-cards .np-entry h2,
body.np-preset-cards .np-entry h3 {
  border-left: 0; padding-left: 0; font-weight: 800; letter-spacing: -.3px;
}
body.np-preset-cards .np-entry h2::before,
body.np-preset-cards .np-entry h3::before {
  content: ''; display: inline-block; width: 9px; height: 9px; border-radius: 3px;
  margin-right: 10px; background: linear-gradient(135deg, var(--sp-brand), var(--sp-brand2));
}
body.np-preset-cards .np-entry blockquote {
  border-left: 3px solid var(--sp-brand); border-radius: 0 12px 12px 0;
  background: var(--sp-soft); padding: 14px 20px; color: var(--sp-sub);
}
body.np-preset-cards .np-pa__act { border-radius: 999px; }
body.np-preset-cards .np-pa__act.is-active { background: var(--sp-soft); color: var(--sp-brand); }

/* G. 暗色 */
body.np-dark.np-preset-cards {
  --sp-ink: #ece9fb; --sp-sub: #a29bbd; --sp-line: #322c4a;
  --sp-surface: #1d1a2b; --sp-soft: #272239;
  --sp-shadow: 0 2px 6px rgba(0, 0, 0, .3), 0 14px 34px rgba(0, 0, 0, .32);
  --sp-shadow-hi: 0 8px 18px rgba(0, 0, 0, .4), 0 24px 56px rgba(0, 0, 0, .5);
  color: var(--sp-ink); background-color: #14121d;
  background-image:
    radial-gradient(920px 460px at 8% -10%, rgba(109, 92, 231, .18), transparent 70%),
    radial-gradient(780px 420px at 96% 2%, rgba(167, 139, 250, .12), transparent 72%);
}
body.np-dark.np-preset-cards .np-btn--primary { background: #fff; color: #5644c9; }
body.np-dark.np-preset-cards .np-footer { background: #191627; }
body.np-dark.np-preset-cards .np-module__more { background: var(--sp-soft); color: #b9a8ff; }
body.np-dark.np-preset-cards .np-module__more:hover { background: var(--sp-brand); color: #fff; }

/* H. 响应式 */
@media (max-width: 1100px) {
  body.np-preset-cards .np-post-grid { --np-cols: 3; }
}
@media (max-width: 900px) {
  body.np-preset-cards .np-post-grid { --np-cols: 2; gap: 16px; }
  body.np-preset-cards .np-single { padding: 26px 24px; }
  body.np-preset-cards .np-header__inner { height: 60px; }
  body.np-preset-cards .np-brand::before { display: none; }
}
@media (max-width: 560px) {
  body.np-preset-cards {
    background-image: radial-gradient(560px 300px at 50% -6%, rgba(109, 92, 231, .13), transparent 72%);
  }
  body.np-preset-cards .np-main { padding-top: 18px; }
  body.np-preset-cards .np-post-grid { --np-cols: 1; gap: 14px; }
  body.np-preset-cards .np-card__thumb::before { display: none; }
  body.np-preset-cards .np-card__body { padding: 14px 16px 16px; }
  body.np-preset-cards .np-card:hover { transform: none; }
  body.np-preset-cards .np-module__title { font-size: 18px; }
  body.np-preset-cards .np-single { padding: 20px 18px; }
  body.np-preset-cards .np-single__title { font-size: 25px; }
  body.np-preset-cards .np-post-item { grid-template-columns: 104px minmax(0, 1fr); gap: 12px; }
  body.np-preset-cards .np-post-item__excerpt { display: none; }
}

/* ==========================================================================
   42.2 极简阅读：纸感、衬线、细线分隔，像一本安静的杂志
   ========================================================================== */

/* A. 令牌与纸感氛围 */
body.np-preset-reading {
  --sp-ink: #26241f;
  --sp-sub: #7c766a;
  --sp-line: #e3ddd0;
  --sp-surface: #fdfbf6;
  --sp-soft: #f4f0e6;
  --sp-brand: #2f6b52;
  --sp-brand2: #8a6d4b;
  --sp-serif: Georgia, "Songti SC", "STSong", "Noto Serif SC", "SimSun", serif;
  color: var(--sp-ink);
  background-color: #faf8f3;
  background-image:
    linear-gradient(90deg, rgba(138, 109, 75, .035) 1px, transparent 1px),
    linear-gradient(rgba(138, 109, 75, .028) 1px, transparent 1px);
  background-size: 32px 32px;
  background-attachment: fixed;
  font-family: var(--sp-serif);
}
body.np-preset-reading .np-main { padding-top: 40px; padding-bottom: 72px; }
body.np-preset-reading .np-container:not(.np-header__inner) { padding: 0 26px; }

/* B. 顶栏：纸白、细线、衬线品牌、字距拉开的导航 */
body.np-preset-reading .np-header {
  background: rgba(253, 251, 246, .96);
  border-bottom: 1px solid var(--sp-line);
  box-shadow: none;
}
body.np-preset-reading .np-header.is-sticky {
  background: rgba(253, 251, 246, .92); backdrop-filter: blur(12px);
}
body.np-preset-reading .np-header__inner { height: 70px; }
body.np-preset-reading .np-brand__name {
  font-family: var(--sp-serif); font-size: 25px; font-weight: 700;
  letter-spacing: 1.5px; color: var(--sp-ink);
}
body.np-preset-reading .np-brand__name em { color: var(--sp-brand); font-style: italic; }
body.np-preset-reading .np-brand::before {
  content: ''; width: 2px; height: 24px; background: var(--sp-brand); margin-right: 4px;
}
body.np-preset-reading .np-search-toggle,
body.np-preset-reading .np-dark-toggle,
body.np-preset-reading .np-translate-toggle {
  border-radius: 2px; border-color: var(--sp-line); color: #6b6558; background: transparent;
}
body.np-preset-reading .np-search-toggle:hover,
body.np-preset-reading .np-dark-toggle:hover,
body.np-preset-reading .np-translate-toggle:hover { color: var(--sp-brand); border-color: var(--sp-brand); }
body.np-preset-reading .np-header__search input {
  border-radius: 2px; border-color: var(--sp-line); background: var(--sp-surface);
}
body.np-preset-reading .np-btn--primary,
body.np-preset-reading .np-header .np-btn--primary {
  background: transparent; border: 1px solid var(--sp-brand); border-radius: 2px;
  color: var(--sp-brand); font-weight: 500; letter-spacing: 1px;
}
body.np-preset-reading .np-btn--primary:hover { background: var(--sp-brand); color: #fff; }
body.np-preset-reading .np-breadcrumb,
body.np-preset-reading .np-crumb {
  color: var(--sp-sub); font-size: 12px; letter-spacing: .6px;
  margin-bottom: 26px; padding-bottom: 12px; border-bottom: 1px solid var(--sp-line);
}

/* C. 模块标题：细线 + 小号字距标题 */
body.np-preset-reading .np-module { margin-bottom: 42px; }
body.np-preset-reading .np-module__head {
  border-bottom: 1px solid var(--sp-line); padding-bottom: 12px; margin-bottom: 22px;
}
body.np-preset-reading .np-module__title {
  font-size: 15px; font-weight: 600; letter-spacing: 3px; color: var(--sp-ink);
  text-transform: none; gap: 12px;
}
body.np-preset-reading .np-module__title::before {
  content: ''; width: 26px; height: 1px; border-radius: 0; background: var(--sp-brand);
}
body.np-preset-reading .np-module__more {
  font-size: 12px; letter-spacing: 1px; color: var(--sp-sub);
}
body.np-preset-reading .np-module__more:hover { color: var(--sp-brand); }

/* D. 列表：去框去底、细线分隔、衬线大标题 */
body.np-preset-reading .np-post-grid { gap: 0; }
body.np-preset-reading .np-card,
body.np-preset-reading .np-post-item {
  border: 0; border-radius: 0; background: transparent; box-shadow: none;
  border-bottom: 1px solid var(--sp-line);
}
body.np-preset-reading .np-card:hover,
body.np-preset-reading .np-post-item:hover { transform: none; box-shadow: none; border-color: var(--sp-line); }
body.np-preset-reading .np-card {
  flex-direction: row; align-items: flex-start; gap: 20px; padding: 0 0 20px;
}
body.np-preset-reading .np-card__thumb {
  flex: 0 0 138px; width: 138px; aspect-ratio: 4 / 3; border-radius: 0;
  order: 2; filter: saturate(.72);
}
body.np-preset-reading .np-card__thumb::after { display: none; }
body.np-preset-reading .np-card__body { padding: 0; order: 1; flex: 1 1 auto; min-width: 0; }
body.np-preset-reading .np-card__title {
  font-family: var(--sp-serif); font-size: 21px; font-weight: 600; line-height: 1.5;
  letter-spacing: .3px; -webkit-line-clamp: 3; margin-bottom: 8px;
}
body.np-preset-reading .np-card__title a,
body.np-preset-reading .np-post-item__title a { color: var(--sp-ink); }
body.np-preset-reading .np-card:hover .np-card__title a,
body.np-preset-reading .np-post-item:hover .np-post-item__title a { color: var(--sp-brand); }
body.np-preset-reading .np-card__body > p {
  color: #6e685c; font-size: 14px; line-height: 1.9; margin-bottom: 10px;
}
body.np-preset-reading .np-post-meta {
  color: var(--sp-sub); font-size: 12px; letter-spacing: .5px;
  border-top: 0; padding-top: 0; margin-top: 0;
}
body.np-preset-reading .np-post-item {
  grid-template-columns: minmax(0, 1fr) 150px; gap: 22px; padding-bottom: 22px; margin-bottom: 20px;
}
body.np-preset-reading .np-post-item__thumb {
  order: 2; border-radius: 0; aspect-ratio: 4 / 3; filter: saturate(.72);
}
body.np-preset-reading .np-post-item__body { order: 1; }
body.np-preset-reading .np-post-item__title {
  font-family: var(--sp-serif); font-size: 22px; font-weight: 600; letter-spacing: .3px;
}
body.np-preset-reading .np-post-item__excerpt { color: #6e685c; font-size: 14px; line-height: 1.9; }
body.np-preset-reading .np-post-item__badge {
  border-radius: 0; background: var(--sp-brand); font-weight: 400; letter-spacing: 1px;
}

/* E. 小工具、页脚 */
body.np-preset-reading .np-widget {
  border: 0; border-top: 1px solid var(--sp-line); border-radius: 0;
  background: transparent; padding: 18px 0 0; box-shadow: none;
}
body.np-preset-reading .np-widget__title {
  font-family: var(--sp-serif); font-size: 14px; font-weight: 600; letter-spacing: 2px;
  border-bottom-color: var(--sp-line);
}
body.np-preset-reading .np-widget__title::before { display: none; }
body.np-preset-reading .np-footer {
  border-top: 1px solid var(--sp-line); background: transparent;
  color: var(--sp-sub); text-align: center; font-size: 13px; letter-spacing: .5px;
}
body.np-preset-reading .np-footer .np-container { padding-top: 8px; }

/* F. 文章页：首字下沉、居中标题、装饰短线与素雅引用 */
body.np-preset-reading .np-single {
  border: 0; box-shadow: none; background: transparent; padding: 0;
}
body.np-preset-reading .np-single__header { text-align: center; margin-bottom: 34px; }
body.np-preset-reading .np-single__title {
  font-family: var(--sp-serif); font-size: clamp(29px, 4vw, 40px);
  font-weight: 600; line-height: 1.45; letter-spacing: .5px; margin-bottom: 18px;
}
body.np-preset-reading .np-single__header::after {
  content: ''; display: block; width: 48px; height: 1px;
  background: var(--sp-brand); margin: 0 auto 20px;
}
body.np-preset-reading .np-single__meta {
  justify-content: center; border-bottom: 0; color: var(--sp-sub);
  font-size: 12.5px; letter-spacing: .6px;
}
body.np-preset-reading .np-single__cats a {
  background: transparent; color: var(--sp-brand); border: 1px solid var(--sp-line);
  border-radius: 0; font-weight: 400; letter-spacing: 1px;
}
body.np-preset-reading .np-entry {
  font-family: var(--sp-serif); font-size: 17px; line-height: 2.05; color: #33302a;
}
body.np-preset-reading .np-entry p { margin-bottom: 1.45em; }
body.np-preset-reading .np-entry > p:first-of-type::first-letter {
  float: left; font-size: 3.1em; line-height: .92; padding: 6px 10px 0 0;
  color: var(--sp-brand); font-weight: 600;
}
body.np-preset-reading .np-entry h2,
body.np-preset-reading .np-entry h3 {
  border-left: 0; padding-left: 0; font-family: var(--sp-serif);
  font-weight: 600; letter-spacing: .5px; text-align: center; margin-top: 42px;
}
body.np-preset-reading .np-entry h2::after,
body.np-preset-reading .np-entry h3::after {
  content: ''; display: block; width: 24px; height: 1px;
  background: var(--sp-line); margin: 12px auto 0;
}
body.np-preset-reading .np-entry blockquote {
  border-left: 0; border-top: 1px solid var(--sp-line);
  border-bottom: 1px solid var(--sp-line); background: transparent;
  padding: 20px 8px; margin: 28px 0; font-style: italic;
  color: #5d584e; text-align: center; font-size: 18px;
}
body.np-preset-reading .np-entry img { border-radius: 0; }
body.np-preset-reading .np-pa__bar { border-top: 1px solid var(--sp-line); border-bottom: 1px solid var(--sp-line); }
body.np-preset-reading .np-pa__act { border-radius: 0; background: transparent; border-color: var(--sp-line); }
body.np-preset-reading .np-pa__act.is-active { background: var(--sp-soft); color: var(--sp-brand); }

/* G. 暗色 */
body.np-dark.np-preset-reading {
  --sp-ink: #ece7dc; --sp-sub: #a49c8c; --sp-line: #3a342a;
  --sp-surface: #1c1a16; --sp-soft: #25221c; --sp-brand: #7fc2a3;
  color: var(--sp-ink); background-color: #161411;
  background-image:
    linear-gradient(90deg, rgba(200, 180, 140, .03) 1px, transparent 1px),
    linear-gradient(rgba(200, 180, 140, .025) 1px, transparent 1px);
}
body.np-dark.np-preset-reading .np-header { background: rgba(28, 26, 22, .96); }
body.np-dark.np-preset-reading .np-card__title a,
body.np-dark.np-preset-reading .np-post-item__title a,
body.np-dark.np-preset-reading .np-brand__name { color: var(--sp-ink); }
body.np-dark.np-preset-reading .np-card__body > p,
body.np-dark.np-preset-reading .np-post-item__excerpt,
body.np-dark.np-preset-reading .np-entry { color: #cbc4b6; }
body.np-dark.np-preset-reading .np-btn--primary { color: var(--sp-brand); border-color: var(--sp-brand); }
body.np-dark.np-preset-reading .np-btn--primary:hover { background: var(--sp-brand); color: #161411; }

/* H. 响应式 */
@media (max-width: 900px) {
  body.np-preset-reading .np-container:not(.np-header__inner) { padding: 0 22px; }
  body.np-preset-reading .np-main { padding-top: 26px; padding-bottom: 56px; }
  body.np-preset-reading .np-header__inner { height: 60px; }
  body.np-preset-reading .np-brand__name { font-size: 21px; }
  body.np-preset-reading .np-brand::before { display: none; }
  body.np-preset-reading .np-single__title { font-size: 30px; }
}
@media (max-width: 560px) {
  body.np-preset-reading { background-image: none; }
  body.np-preset-reading .np-container:not(.np-header__inner) { padding: 0 18px; }
  body.np-preset-reading .np-main { padding-top: 18px; }
  body.np-preset-reading .np-card { flex-direction: column; gap: 0; }
  body.np-preset-reading .np-card__thumb { order: 1; flex: none; width: 100%; aspect-ratio: 16 / 9; margin-bottom: 12px; }
  body.np-preset-reading .np-card__body { order: 2; }
  body.np-preset-reading .np-card__title { font-size: 19px; }
  body.np-preset-reading .np-card__body > p { display: none; }
  body.np-preset-reading .np-post-item { grid-template-columns: 1fr; gap: 0; }
  body.np-preset-reading .np-post-item__thumb { order: 1; width: 100%; aspect-ratio: 16 / 9; margin-bottom: 12px; }
  body.np-preset-reading .np-post-item__body { order: 2; }
  body.np-preset-reading .np-post-item__excerpt { display: none; }
  body.np-preset-reading .np-post-item__title { font-size: 19px; }
  body.np-preset-reading .np-module__title { letter-spacing: 2px; font-size: 14px; }
  body.np-preset-reading .np-entry { font-size: 16px; line-height: 1.95; }
  body.np-preset-reading .np-entry > p:first-of-type::first-letter { float: none; font-size: inherit; padding: 0; color: inherit; }
  body.np-preset-reading .np-single__title { font-size: 26px; }
  body.np-preset-reading .np-entry h2,
  body.np-preset-reading .np-entry h3 { text-align: left; margin-top: 32px; }
  body.np-preset-reading .np-entry h2::after,
  body.np-preset-reading .np-entry h3::after { margin-left: 0; }
}

/* ==========================================================================
   42.3 导购商城：暖白、橙金强调、明确的商品卡与转化层级
   ========================================================================== */

/* A. 令牌与暖白氛围 */
body.np-preset-shop {
  --sp-ink: #2a211c;
  --sp-sub: #8a7a70;
  --sp-line: #f0e3da;
  --sp-surface: #ffffff;
  --sp-soft: #fff3ea;
  --sp-brand: #e0562a;
  --sp-brand2: #ff9a3c;
  --sp-shadow: 0 1px 3px rgba(120, 60, 30, .05), 0 8px 22px rgba(140, 70, 30, .07);
  --sp-shadow-hi: 0 6px 14px rgba(160, 70, 25, .12), 0 20px 44px rgba(180, 80, 25, .17);
  --sp-radius: 12px;
  color: var(--sp-ink);
  background-color: #fffaf7;
  background-image: radial-gradient(900px 400px at 50% -12%, rgba(255, 154, 60, .12), transparent 72%);
  background-attachment: fixed;
  background-repeat: no-repeat;
}
body.np-preset-shop .np-main { padding-top: 26px; }

/* B. 顶栏：白底 + 顶部橙金渐变条 + 胶囊导航 */
body.np-preset-shop .np-header {
  background: #fff; border-bottom: 1px solid var(--sp-line);
  box-shadow: 0 3px 14px rgba(120, 60, 30, .05);
}
body.np-preset-shop .np-header::before {
  content: ''; position: absolute; left: 0; right: 0; top: 0; height: 3px;
  background: linear-gradient(90deg, var(--sp-brand), var(--sp-brand2), #ffc46b);
}
body.np-preset-shop .np-header.is-sticky { background: rgba(255, 255, 255, .94); backdrop-filter: blur(12px); }
body.np-preset-shop .np-header__inner { height: 70px; }
body.np-preset-shop .np-brand__name {
  font-size: 22px; font-weight: 900; letter-spacing: -.6px; color: var(--sp-ink);
}
body.np-preset-shop .np-brand__name em { color: var(--sp-brand); }
body.np-preset-shop .np-brand::after {
  content: '好价'; font-size: 10px; font-weight: 700; letter-spacing: .5px;
  color: #fff; background: linear-gradient(135deg, var(--sp-brand), var(--sp-brand2));
  border-radius: 4px; padding: 2px 6px; margin-left: 2px;
}
body.np-preset-shop .np-search-toggle,
body.np-preset-shop .np-dark-toggle,
body.np-preset-shop .np-translate-toggle {
  border-radius: 10px; border-color: var(--sp-line); color: #7a6a60; background: var(--sp-soft);
}
body.np-preset-shop .np-search-toggle:hover,
body.np-preset-shop .np-dark-toggle:hover,
body.np-preset-shop .np-translate-toggle:hover { color: var(--sp-brand); border-color: var(--sp-brand); }
body.np-preset-shop .np-header__search input {
  border-radius: 999px; border-color: var(--sp-line); background: var(--sp-soft);
}
/* 修 1.8.52 的真实缺陷：原规则把主色按钮文字设成主色，与橙色背景同色导致文字不可见。 */
body.np-preset-shop .np-btn--primary,
body.np-preset-shop .np-header .np-btn--primary,
body.np-preset-shop .np-btn--primary:hover {
  background: linear-gradient(135deg, var(--sp-brand), var(--sp-brand2));
  border-color: transparent; color: #fff; border-radius: 999px;
  font-weight: 700; box-shadow: 0 4px 12px rgba(224, 86, 42, .28);
}
body.np-preset-shop .np-btn--ghost { color: var(--sp-brand); border-color: var(--sp-brand); border-radius: 999px; }
body.np-preset-shop .np-breadcrumb,
body.np-preset-shop .np-crumb { color: var(--sp-sub); font-size: 12.5px; margin-bottom: 16px; }
body.np-preset-shop .np-breadcrumb b,
body.np-preset-shop .np-crumb b { color: var(--sp-brand); }

/* C. 模块头、分类胶囊、网格 */
body.np-preset-shop .np-module { margin-bottom: 30px; }
body.np-preset-shop .np-module__head {
  border-bottom: 2px solid var(--sp-line); padding-bottom: 11px; margin-bottom: 18px;
}
body.np-preset-shop .np-module__title {
  font-size: 21px; font-weight: 800; letter-spacing: -.4px; color: var(--sp-ink); gap: 10px;
}
body.np-preset-shop .np-module__title::before {
  width: 5px; height: 20px; border-radius: 3px;
  background: linear-gradient(180deg, var(--sp-brand), var(--sp-brand2));
}
body.np-preset-shop .np-module__more {
  color: var(--sp-brand); font-weight: 700; font-size: 13px;
}
body.np-preset-shop .np-module__more:hover { color: #b8411c; }
body.np-preset-shop .np-post-grid { gap: 18px; }
body.np-preset-shop .np-cat,
body.np-preset-shop .np-icp__chip {
  border-radius: 999px; border-color: var(--sp-line); background: #fff;
  color: #6b5b50; transition: var(--np-transition);
}
body.np-preset-shop .np-cat:hover,
body.np-preset-shop .np-icp__chip:hover {
  border-color: transparent; color: #fff;
  background: linear-gradient(135deg, var(--sp-brand), var(--sp-brand2));
}
body.np-preset-shop .np-slider { border-radius: var(--sp-radius); }
body.np-preset-shop .np-slider__tag {
  border-radius: 999px; background: linear-gradient(135deg, var(--sp-brand), var(--sp-brand2));
}

/* D. 商品卡：方形图、推荐角标、悬浮圆形按钮、价格感元信息 */
body.np-preset-shop .np-card {
  border: 1px solid var(--sp-line); border-radius: var(--sp-radius);
  background: var(--sp-surface); box-shadow: var(--sp-shadow);
  transition: transform 240ms cubic-bezier(.2, .8, .2, 1), box-shadow 240ms ease;
}
body.np-preset-shop .np-card:hover {
  transform: translateY(-5px); box-shadow: var(--sp-shadow-hi);
  border-color: rgba(224, 86, 42, .4);
}
body.np-preset-shop .np-card__thumb { aspect-ratio: 1 / 1; }
body.np-preset-shop .np-card__thumb::after {
  content: '荐'; position: absolute; z-index: 2; right: 10px; top: 10px;
  width: 26px; height: 26px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 700; color: #fff;
  background: linear-gradient(135deg, var(--sp-brand), var(--sp-brand2));
  box-shadow: 0 3px 10px rgba(224, 86, 42, .4);
}
body.np-preset-shop .np-card__thumb::before {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, transparent 70%, rgba(42, 33, 28, .1));
}
body.np-preset-shop .np-card__body { padding: 13px 15px 15px; position: relative; }
body.np-preset-shop .np-card__title {
  font-size: 15px; font-weight: 700; line-height: 1.5; margin-bottom: 8px;
  padding-right: 4px;
}
body.np-preset-shop .np-card__title a { color: var(--sp-ink); }
body.np-preset-shop .np-card:hover .np-card__title a { color: var(--sp-brand); }
body.np-preset-shop .np-card__body > p { color: var(--sp-sub); font-size: 12.5px; line-height: 1.65; }
body.np-preset-shop .np-post-meta {
  color: var(--sp-sub); font-size: 12px; gap: 10px;
  border-top: 1px dashed var(--sp-line); padding-top: 10px; margin-top: 6px;
}
body.np-preset-shop .np-post-meta::before {
  content: ''; width: 6px; height: 6px; border-radius: 50%;
  background: linear-gradient(135deg, var(--sp-brand), var(--sp-brand2)); flex: none;
}
body.np-preset-shop .np-post-meta span:last-child {
  color: var(--sp-brand); font-weight: 700; margin-left: auto;
  background: var(--sp-soft); border-radius: 999px; padding: 3px 10px;
}
body.np-preset-shop .np-card__body::after {
  content: '\2192'; position: absolute; right: 14px; bottom: 46px;
  width: 30px; height: 30px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 15px; color: #fff;
  background: linear-gradient(135deg, var(--sp-brand), var(--sp-brand2));
  box-shadow: 0 4px 12px rgba(224, 86, 42, .3);
  opacity: 0; transform: translateY(6px); transition: var(--np-transition);
}
body.np-preset-shop .np-card:hover .np-card__body::after { opacity: 1; transform: translateY(0); }
body.np-preset-shop .np-post-item {
  border-bottom-color: var(--sp-line); padding-bottom: 18px; gap: 18px;
}
body.np-preset-shop .np-post-item__thumb { border-radius: var(--sp-radius); }
body.np-preset-shop .np-post-item__title { font-weight: 700; }
body.np-preset-shop .np-post-item__badge {
  background: linear-gradient(135deg, var(--sp-brand), var(--sp-brand2)); border-radius: 999px;
}

/* E. 小工具、排行、页脚 */
body.np-preset-shop .np-widget {
  border: 1px solid var(--sp-line); border-radius: var(--sp-radius);
  background: var(--sp-surface); box-shadow: var(--sp-shadow); padding: 18px;
}
body.np-preset-shop .np-widget__title {
  border-bottom: 2px solid var(--sp-line); font-weight: 800;
}
body.np-preset-shop .np-widget__title::before {
  width: 5px; height: 16px; border-radius: 3px;
  background: linear-gradient(180deg, var(--sp-brand), var(--sp-brand2));
}
body.np-preset-shop .np-pick__rank {
  border-radius: 6px; background: var(--sp-soft); color: var(--sp-brand); font-weight: 800;
}
body.np-preset-shop .np-pick__item:nth-child(-n+3) .np-pick__rank {
  background: linear-gradient(135deg, var(--sp-brand), var(--sp-brand2)); color: #fff;
}
body.np-preset-shop .np-footer {
  border-top: 3px solid var(--sp-brand); background: #fff3ea; color: var(--sp-sub);
  box-shadow: inset 0 8px 14px -12px rgba(224, 86, 42, .5);
}

/* F. 文章页与互动条 */
body.np-preset-shop .np-single {
  border: 1px solid var(--sp-line); border-radius: var(--sp-radius);
  background: var(--sp-surface); box-shadow: var(--sp-shadow); padding: 30px 34px;
}
body.np-preset-shop .np-single__title {
  font-size: clamp(27px, 3.4vw, 36px); font-weight: 800; letter-spacing: -.6px;
}
body.np-preset-shop .np-single__meta { border-bottom-color: var(--sp-line); }
body.np-preset-shop .np-single__cats a {
  border-radius: 999px; background: var(--sp-soft); color: var(--sp-brand); font-weight: 700;
}
body.np-preset-shop .np-entry { font-size: 16px; line-height: 1.9; }
body.np-preset-shop .np-entry h2,
body.np-preset-shop .np-entry h3 { border-left-color: var(--sp-brand); font-weight: 800; }
body.np-preset-shop .np-entry blockquote {
  border-left: 3px solid var(--sp-brand2); background: var(--sp-soft); border-radius: 0 8px 8px 0;
}
body.np-preset-shop .np-pa__act { border-radius: 999px; }
body.np-preset-shop .np-pa__act.is-active { background: var(--sp-soft); color: var(--sp-brand); }

/* G. 暗色 */
body.np-dark.np-preset-shop {
  --sp-ink: #f3e9e3; --sp-sub: #b7a298; --sp-line: #382c26;
  --sp-surface: #211b18; --sp-soft: #2c221d;
  --sp-shadow: 0 2px 6px rgba(0, 0, 0, .3), 0 12px 30px rgba(0, 0, 0, .34);
  --sp-shadow-hi: 0 8px 18px rgba(0, 0, 0, .42), 0 24px 52px rgba(0, 0, 0, .5);
  color: var(--sp-ink); background-color: #171310;
  background-image: radial-gradient(900px 400px at 50% -12%, rgba(255, 154, 60, .1), transparent 72%);
}
body.np-dark.np-preset-shop .np-header,
body.np-dark.np-preset-shop .np-header.is-sticky { background: #211b18; }
body.np-dark.np-preset-shop .np-cat,
body.np-dark.np-preset-shop .np-icp__chip { background: var(--sp-surface); color: #cbbdb4; }
body.np-dark.np-preset-shop .np-footer { background: #1d1714; }
body.np-dark.np-preset-shop .np-brand__name { color: var(--sp-ink); }
body.np-dark.np-preset-shop .np-card__title a,
body.np-dark.np-preset-shop .np-post-item__title a { color: var(--sp-ink); }

/* H. 响应式 */
@media (max-width: 1100px) {
  body.np-preset-shop .np-post-grid { --np-cols: 3; }
}
@media (max-width: 900px) {
  body.np-preset-shop .np-post-grid { --np-cols: 2; gap: 14px; }
  body.np-preset-shop .np-header__inner { height: 60px; }
  body.np-preset-shop .np-brand::after { display: none; }
  body.np-preset-shop .np-single { padding: 24px 22px; }
}
@media (max-width: 560px) {
  body.np-preset-shop .np-main { padding-top: 16px; }
  body.np-preset-shop .np-post-grid { --np-cols: 2; gap: 10px; }
  body.np-preset-shop .np-card__body { padding: 10px 11px 12px; }
  body.np-preset-shop .np-card__title { font-size: 13.5px; }
  body.np-preset-shop .np-card__body > p { display: none; }
  body.np-preset-shop .np-card__thumb::after { width: 22px; height: 22px; font-size: 10px; right: 7px; top: 7px; }
  body.np-preset-shop .np-card__body::after { display: none; }
  body.np-preset-shop .np-post-meta span:last-child { display: none; }
  body.np-preset-shop .np-module__title { font-size: 18px; }
  body.np-preset-shop .np-single { padding: 18px 16px; }
  body.np-preset-shop .np-single__title { font-size: 24px; }
  body.np-preset-shop .np-post-item { grid-template-columns: 100px minmax(0, 1fr); gap: 12px; }
  body.np-preset-shop .np-post-item__excerpt { display: none; }
}
@media (max-width: 340px) {
  body.np-preset-shop .np-post-grid { --np-cols: 1; }
}

/* ==========================================================================
   42.4 全局收尾：通用可读性、暗色兜底、减少动效
   ========================================================================== */
@media (max-width: 560px) {
  body.np-preset-cards .np-header__actions,
  body.np-preset-reading .np-header__actions,
  body.np-preset-shop .np-header__actions { gap: 6px; }
  body.np-preset-cards .np-btn--primary,
  body.np-preset-reading .np-btn--primary,
  body.np-preset-shop .np-btn--primary { padding: 0 13px; height: 34px; font-size: 13px; }
  body.np-preset-cards .np-nav,
  body.np-preset-reading .np-nav,
  body.np-preset-shop .np-nav { overflow-x: auto; scrollbar-width: none; }
  body.np-preset-cards .np-nav::-webkit-scrollbar,
  body.np-preset-reading .np-nav::-webkit-scrollbar,
  body.np-preset-shop .np-nav::-webkit-scrollbar { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  body.np-preset-cards .np-card,
  body.np-preset-shop .np-card,
  body.np-preset-shop .np-card__body::after,
  body.np-preset-cards .np-module__more { transition: none; }
  body.np-preset-cards .np-card:hover,
  body.np-preset-shop .np-card:hover { transform: none; }
}


/* ==========================================================================
   43. 1.8.55 页面样式方案：手机抽屉与顶栏细节修复
   ========================================================================== */

/* 43.1 方案顶栏导航规则只在桌面生效。
   1.8.54 的 .np-nav 规则没有限定宽度，而 960px 以下 .np-nav 会被 JS 搬出
   header、变成左侧浅色抽屉。白字胶囊规则于是把抽屉里所有 <a>（主菜单、
   翻译项、会员横幅、圆钮、品牌链接）一起染白，在 --np-bg-soft 浅底上
   对比度只有约 1.06:1，文字几乎不可读；padding / border-radius 也被改掉。
   这里把原规则原样收进 min-width 媒体：桌面表现逐条不变，手机端自动回到
   主题抽屉的深色字 + 主色高亮，并借 --np-* 令牌自动适配亮色与暗色。
   注：960px 是主题切换抽屉的断点，用 961px 保证两者边界完全对齐。 */
@media (min-width: 961px) {


  body.np-preset-cards .np-nav a {
    color: rgba(255, 255, 255, .88); font-size: 14px; font-weight: 600;
    padding: 7px 14px; border-radius: 999px;
  }
  body.np-preset-cards .np-nav a:hover,
  body.np-preset-cards .np-nav .current-menu-item > a,
  body.np-preset-cards .np-nav .current-menu-ancestor > a {
    color: var(--sp-brand); background: #fff;
  }
  body.np-preset-cards .np-nav ul ul {
    background: #fff; border: 0; border-radius: 14px;
    box-shadow: 0 14px 40px rgba(60, 45, 130, .2); padding: 8px;
  }
  body.np-preset-cards .np-nav ul ul a { color: var(--sp-ink); border-radius: 8px; }
  body.np-dark.np-preset-cards .np-nav a:hover,
  body.np-dark.np-preset-cards .np-nav .current-menu-item > a { color: #fff; background: rgba(255, 255, 255, .16); }
  body.np-dark.np-preset-cards .np-nav ul ul { background: #1d1a2b; }
  body.np-dark.np-preset-cards .np-nav ul ul a { color: var(--sp-ink); }
  body.np-preset-reading .np-nav { gap: 6px; }
  body.np-preset-reading .np-nav a {
    font-size: 14px; font-weight: 400; letter-spacing: 1.2px;
    color: #5d584e; border-radius: 0; padding: 8px 11px;
  }
  body.np-preset-reading .np-nav a:hover,
  body.np-preset-reading .np-nav .current-menu-item > a,
  body.np-preset-reading .np-nav .current-menu-ancestor > a {
    color: var(--sp-brand); background: transparent;
    box-shadow: inset 0 -2px 0 var(--sp-brand);
  }
  body.np-preset-reading .np-nav ul ul {
    border: 1px solid var(--sp-line); border-radius: 0; box-shadow: 0 12px 30px rgba(60, 50, 30, .12);
    background: var(--sp-surface);
  }
  body.np-preset-reading .np-nav ul ul a { color: #5d584e; border-radius: 0; }
  body.np-dark.np-preset-reading .np-nav a { color: #c3bbac; }
  body.np-dark.np-preset-reading .np-nav a:hover,
  body.np-dark.np-preset-reading .np-nav .current-menu-item > a { color: var(--sp-brand); }
  body.np-preset-shop .np-nav a {
    font-size: 14px; font-weight: 600; color: #5f534b; border-radius: 999px; padding: 7px 14px;
  }
  body.np-preset-shop .np-nav a:hover,
  body.np-preset-shop .np-nav .current-menu-item > a,
  body.np-preset-shop .np-nav .current-menu-ancestor > a {
    color: #fff; background: linear-gradient(135deg, var(--sp-brand), var(--sp-brand2));
  }
  body.np-preset-shop .np-nav ul ul {
    border-color: var(--sp-line); border-radius: var(--sp-radius);
    box-shadow: 0 14px 36px rgba(140, 70, 30, .16);
  }
  body.np-preset-shop .np-nav ul ul a { color: #5f534b; border-radius: 8px; }
  body.np-dark.np-preset-shop .np-nav a { color: #cbbdb4; }
  body.np-dark.np-preset-shop .np-nav a:hover,
  body.np-dark.np-preset-shop .np-nav .current-menu-item > a { color: #fff; }
  body.np-dark.np-preset-shop .np-nav ul ul { background: #211b18; }
  body.np-dark.np-preset-shop .np-nav ul ul a { color: #cbbdb4; }
}



/* 43.2 紫渐变顶栏的品牌：标题原本走 .np-brand__title，1.8.54 只改了
   .np-brand__name，导致用图片 logo 的站点标题仍是深色、压在紫底上发暗。
   统一限定 .np-header，避免把白底抽屉里的品牌文字也染白。 */
body.np-preset-cards .np-header .np-brand__title,
body.np-preset-cards .np-header .np-brand__name { color: #fff; }
body.np-preset-cards .np-header .np-brand__tagline { color: rgba(255, 255, 255, .74); }
body.np-preset-cards .np-header .np-brand__link:hover .np-brand__title { color: #ffe9a8; }
/* 1.8.54 给品牌加的 26px 白黄渐变方块，在带图片 logo 的站点会孤立地挂在
   文字后面（用户截图里那个「黄色圆」）。有图片时直接隐藏。 */
body.np-preset-cards .np-brand:has(.np-brand__img)::before { display: none; }
/* 纯文字站点则收缩成 10px 渐变圆点，不再和 logo 抢视觉。 */
body.np-preset-cards .np-brand::before {
  width: 10px; height: 10px; border-radius: 50%;
  background: linear-gradient(135deg, #fff, #ffe9a8);
  box-shadow: 0 0 0 3px rgba(255, 255, 255, .18);
}
/* 兜底：万一主题/子主题在抽屉里也输出 .np-brand__name，保持深色可读。 */
@media (max-width: 960px) {
  body.np-preset-cards .np-nav .np-brand__name,
  body.np-preset-cards .np-nav .np-brand__title { color: var(--np-text); }
}

/* 43.3 轮播占位底：主题 .np-slider 用 --np-bg-deep(#0f1419)。浅色方案下
   首图还没加载完时，顶栏下方会先露出一条黑带（用户截图里那条黑线），
   与浅色氛围冲突。改为各方案的浅色底，图片加载后自然被完全盖住。 */
body.np-preset-cards .np-slider { background: #e8e3fb; }
body.np-preset-reading .np-slider { background: #eee9df; }
body.np-preset-shop .np-slider { background: #fff1e6; }
body.np-dark.np-preset-cards .np-slider { background: #272239; }
body.np-dark.np-preset-reading .np-slider { background: #29251f; }
body.np-dark.np-preset-shop .np-slider { background: #2b211c; }


/* 43.4 抽屉里「当前语言」的可读性。主题用 --np-primary 高亮活动项，
   而导购商城的主色是亮橙 #e0562a，白底上只有约 3.79:1（小字低于
   WCAG AA 4.5:1）。三套方案统一改用更深的主色，亮暗色都达标。 */
@media (max-width: 960px) {
  body.np-preset-cards .np-nav .np-translate-menu__item.is-active,
  body.np-preset-reading .np-nav .np-translate-menu__item.is-active,
  body.np-preset-shop .np-nav .np-translate-menu__item.is-active,
  body.np-preset-cards .np-nav .np-translate-menu__item.is-active em,
  body.np-preset-reading .np-nav .np-translate-menu__item.is-active em,
  body.np-preset-shop .np-nav .np-translate-menu__item.is-active em {
    color: var(--np-primary-dark, var(--np-text));
  }
}


/* ==========================================================================
   44. 1.8.56 页面样式方案：明暗切换修复（快捷工具条 + 暗色顶栏）
   ==========================================================================

   问题：1.8.54 第 42 章给三套方案的 .np-search-toggle / .np-dark-toggle /
   .np-translate-toggle 写了「顶栏专用」配色（卡片社区是白字 + 半透明白底 +
   白边 + 36px / 12px 圆角），但没有限定 .np-header。手机端头部这三个按钮
   被隐藏，唯一能切换明暗的入口是快捷工具条里那一份；白色工具条上的
   白图标 + 半透明白底对比度只有 1.00:1，看起来就是一个空白格，用户根本
   看不见、也找不到切换入口。切到暗色后按钮仍是半透明白块，且图标永远是
   月亮，没有任何状态反馈。

   修复（本章只追加，1~43 章逐字不动）：
   - 44.0 按钮补太阳图标，三套方案暗色下月亮 -> 太阳；
   - 44.1 工具条内三类图标按钮统一回 40px / 10px / --np-* 令牌配色，
     桌面亮色顶栏不受影响（选择器都带 .np-side-tools）；
   - 44.2 暗色态给明暗按钮金色高亮，一眼能看出当前状态；
   - 44.3 卡片社区暗色顶栏改深紫渐变，不再与暗色页面撕裂；
   - 44.4 极简阅读 / 导购商城暗色顶栏的图标按钮改浅色，避免深底深字。
   资讯杂志（无 np-preset-* 类）全部规则都不命中，保持 1.8.55 表现。
   ========================================================================== */

/* 44.0 新增的太阳 SVG 默认收起，避免与月亮叠成两个图标。
   只有三套方案在暗色下切成太阳；资讯杂志保持原来的单个月亮。 */
.np-dark-toggle__icon--sun { display: none; }
body.np-dark.np-preset-cards .np-dark-toggle__icon--sun,
body.np-dark.np-preset-reading .np-dark-toggle__icon--sun,
body.np-dark.np-preset-shop .np-dark-toggle__icon--sun { display: block; }
body.np-dark.np-preset-cards .np-dark-toggle__icon--moon,
body.np-dark.np-preset-reading .np-dark-toggle__icon--moon,
body.np-dark.np-preset-shop .np-dark-toggle__icon--moon { display: none; }

/* 44.1 快捷工具条里的图标按钮：解除第 42 章顶栏配色的污染。
   body.np-preset-* .np-side-tools .np-xxx-toggle 特异性 (0,3,1)，
   高于第 42 章 (0,2,1)，且不带 .np-header，桌面顶栏外观逐像素不变。 */
body.np-preset-cards .np-side-tools .np-search-toggle,
body.np-preset-cards .np-side-tools .np-dark-toggle,
body.np-preset-cards .np-side-tools .np-translate-toggle,
body.np-preset-reading .np-side-tools .np-search-toggle,
body.np-preset-reading .np-side-tools .np-dark-toggle,
body.np-preset-reading .np-side-tools .np-translate-toggle,
body.np-preset-shop .np-side-tools .np-search-toggle,
body.np-preset-shop .np-side-tools .np-dark-toggle,
body.np-preset-shop .np-side-tools .np-translate-toggle {
  width: 40px;
  height: 40px;
  border: 1px solid var(--np-line);
  border-radius: 10px;
  background: var(--np-bg);
  color: var(--np-text-2);
}
body.np-preset-cards .np-side-tools .np-search-toggle:hover,
body.np-preset-cards .np-side-tools .np-dark-toggle:hover,
body.np-preset-cards .np-side-tools .np-translate-toggle:hover,
body.np-preset-reading .np-side-tools .np-search-toggle:hover,
body.np-preset-reading .np-side-tools .np-dark-toggle:hover,
body.np-preset-reading .np-side-tools .np-translate-toggle:hover,
body.np-preset-shop .np-side-tools .np-search-toggle:hover,
body.np-preset-shop .np-side-tools .np-dark-toggle:hover,
body.np-preset-shop .np-side-tools .np-translate-toggle:hover {
  color: var(--np-primary);
  border-color: var(--np-primary);
  background: var(--np-primary-soft);
}

/* 44.2 暗色态：明暗按钮金色高亮 + 太阳图标，状态一眼可辨。
   用半透明金底叠加在深色工具条上，与相邻按钮明显区分但不过分抢眼。 */
body.np-dark.np-preset-cards .np-side-tools .np-dark-toggle,
body.np-dark.np-preset-reading .np-side-tools .np-dark-toggle,
body.np-dark.np-preset-shop .np-side-tools .np-dark-toggle {
  color: #f5d76e;
  border-color: rgba(245, 215, 110, .42);
  background: rgba(245, 215, 110, .10);
}
body.np-dark.np-preset-cards .np-side-tools .np-dark-toggle:hover,
body.np-dark.np-preset-reading .np-side-tools .np-dark-toggle:hover,
body.np-dark.np-preset-shop .np-side-tools .np-dark-toggle:hover {
  color: #ffe9a8;
  border-color: rgba(245, 215, 110, .72);
  background: rgba(245, 215, 110, .20);
}

/* 44.3 卡片社区暗色顶栏：1.8.54 的亮紫渐变在暗色页面里像一条没切换的
   亮带。压深成同色系深紫，白字 / 白图标仍然清晰；sticky 态一并覆盖。 */
body.np-dark.np-preset-cards .np-header,
body.np-dark.np-preset-cards .np-header.is-sticky {
  background: linear-gradient(105deg, #241e3a 0%, #2e2650 46%, #3b2f63 100%);
  border-bottom-color: rgba(255, 255, 255, .12);
  box-shadow: 0 6px 24px rgba(0, 0, 0, .28);
}
body.np-dark.np-preset-cards .np-header .np-dark-toggle { color: #ffe9a8; }

/* 44.4 极简阅读 / 导购商城：暗色下顶栏已变深，但第 42 章给图标按钮写死了
   深灰字（reading #6b6558 / shop #7a6a60），压在深底上几乎看不见。
   统一改成方案暗色令牌的浅色字 + 弱白底 / 弱白边。 */
body.np-dark.np-preset-reading .np-header .np-search-toggle,
body.np-dark.np-preset-reading .np-header .np-dark-toggle,
body.np-dark.np-preset-reading .np-header .np-translate-toggle,
body.np-dark.np-preset-shop .np-header .np-search-toggle,
body.np-dark.np-preset-shop .np-header .np-dark-toggle,
body.np-dark.np-preset-shop .np-header .np-translate-toggle {
  color: var(--np-text-2);
  border-color: rgba(255, 255, 255, .24);
  background: rgba(255, 255, 255, .06);
}
body.np-dark.np-preset-reading .np-header .np-search-toggle:hover,
body.np-dark.np-preset-reading .np-header .np-dark-toggle:hover,
body.np-dark.np-preset-reading .np-header .np-translate-toggle:hover,
body.np-dark.np-preset-shop .np-header .np-search-toggle:hover,
body.np-dark.np-preset-shop .np-header .np-dark-toggle:hover,
body.np-dark.np-preset-shop .np-header .np-translate-toggle:hover {
  color: var(--np-primary);
  border-color: var(--np-primary);
  background: rgba(255, 255, 255, .12);
}

/* ==========================================================================
   45. 1.8.57 参考 salongweb.com / qcwlseo.com 新增的 6 个小工具
   --------------------------------------------------------------------------
   来源对照：
     qcwlseo.com  -> 资源卡片（缩略图 + 价格角标）、会员套餐（四档定价）、
                    热门榜单（三榜 TAB + 序号）、专题合集（封面 + 文章清单）
     salongweb.com -> 双语服务卡、联系我们（信息清单 + 双二维码）
   约定：
   - 前缀统一 .np-site-，不与第 41/42/43/44 章任何规则冲突；
   - 颜色全部走 --np-* 设计令牌，亮 / 暗色与四套页面样式自动跟随；
   - 列数消费第 41 章的 --np-wx-cols（单实例列数 + 侧栏自动降级），
     超窄屏再强制降列，保证 375px 不横向溢出；
   - 榜单 TAB 用 radio + :checked 实现，无 JS 也能切换；
   - 图片缺失用 CSS 占位，不产生破图；尊重 prefers-reduced-motion。
   ========================================================================== */

/* 45.0 公共 ---------------------------------------------------------------- */
.np-site-empty {
  padding: 18px 12px;
  color: var(--np-text-2);
  font-size: 13px;
  text-align: center;
}
.np-site-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  font-size: 17px;
  line-height: 1;
  color: var(--np-primary-dark, #135e96);
}
.np-site-icon img { width: 100%; height: 100%; object-fit: contain; }
.np-site-icon--text {
  font-size: 13px;
  font-weight: 700;
  border-radius: 8px;
  background: var(--np-primary-soft);
}
.np-site-icon--dot::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--np-primary-dark, #135e96);
}

/* 45.1 NP 资源卡片 -------------------------------------------------------- */
.np-site-cards {
  display: grid;
  grid-template-columns: repeat(var(--np-wx-cols, 4), minmax(0, 1fr));
  gap: 16px;
}
.np-site-card {
  display: block;
  overflow: hidden;
  min-width: 0;
  color: var(--np-text);
  text-decoration: none;
  background: var(--np-bg);
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  transition: transform var(--np-transition), box-shadow var(--np-transition), border-color var(--np-transition);
}
a.np-site-card:hover {
  transform: translateY(-2px);
  border-color: var(--np-primary-dark, #135e96);
  box-shadow: var(--np-shadow);
}
.np-site-card__media {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--np-bg-soft);
}
.np-site-card__media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.np-site-card__ph,
.np-site-series__ph {
  display: block;
  width: 100%;
  height: 100%;
  background:
    linear-gradient(135deg, var(--np-primary-soft), transparent 62%),
    repeating-linear-gradient(45deg, transparent 0 12px, rgba(127, 140, 160, .07) 12px 24px),
    var(--np-bg-soft);
}
.np-site-card__badge {
  position: absolute;
  top: 8px;
  left: 8px;
  padding: 3px 9px;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.4;
  color: #fff;
  background: var(--np-primary-dark, #135e96);
  border-radius: 5px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, .18);
}
.np-site-card__body { display: block; padding: 11px 12px 13px; }
.np-site-card__cat {
  display: block;
  margin-bottom: 4px;
  font-size: 11px;
  color: var(--np-primary-dark, #135e96);
}
.np-site-card__title {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.5;
  color: var(--np-text);
  min-height: 42px;
}
.np-site-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 10px;
  margin-top: 9px;
  font-size: 11px;
  color: var(--np-text-2);
}

/* 45.2 NP 会员套餐 -------------------------------------------------------- */
.np-site-pricing {
  display: grid;
  grid-template-columns: repeat(var(--np-wx-cols, 4), minmax(0, 1fr));
  gap: 14px;
  align-items: stretch;
}
.np-site-plan {
  --sp-tint: rgba(79, 116, 220, .10);
  --sp-tint-ink: #3a56b0;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 0;
  padding: 20px 14px 18px;
  text-align: center;
  background: var(--np-bg);
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  transition: transform var(--np-transition), box-shadow var(--np-transition);
}
.np-site-pricing--soft .np-site-plan { border-color: transparent; background: var(--sp-tint); }
.np-site-pricing--soft .np-site-plan:hover,
.np-site-plan:hover { transform: translateY(-2px); box-shadow: var(--np-shadow); }
.np-site-plan:nth-child(4n+2) { --sp-tint: rgba(156, 106, 210, .12); --sp-tint-ink: #7a4bb0; }
.np-site-plan:nth-child(4n+3) { --sp-tint: rgba(60, 160, 110, .12);  --sp-tint-ink: #26734f; }
.np-site-plan:nth-child(4n+4) { --sp-tint: rgba(214, 100, 150, .12);  --sp-tint-ink: #a13f70; }
.np-site-plan.is-hot { border-color: var(--np-primary-dark, #135e96); }
.np-site-plan__ribbon {
  position: absolute;
  top: -1px;
  right: -1px;
  padding: 3px 10px;
  font-size: 11px;
  color: #fff;
  background: var(--np-primary-dark, #135e96);
  border-radius: 0 var(--np-radius) 0 8px;
}
.np-site-plan__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  color: var(--sp-tint-ink);
}
.np-site-plan__icon svg { width: 30px; height: 30px; }
.np-site-plan__name {
  margin: 4px 0 6px;
  font-size: 14px;
  font-weight: 600;
  color: var(--np-text);
}
.np-site-plan__price { display: block; line-height: 1.2; }
.np-site-plan__price b { font-size: 28px; font-weight: 700; color: var(--np-text); }
.np-site-plan__price b small { font-size: 15px; font-weight: 600; }
.np-site-plan__price s { margin-left: 5px; font-size: 13px; color: var(--np-text-2); }
.np-site-plan__period {
  display: inline-block;
  margin: 7px 0 10px;
  padding: 2px 12px;
  font-size: 11px;
  color: var(--np-text-2);
  background: var(--np-bg-soft);
  border-radius: 20px;
}
.np-site-plan__feat {
  width: 100%;
  margin: 0 0 14px;
  padding: 12px 0 0;
  list-style: none;
  border-top: 1px solid var(--np-line);
  text-align: left;
}
.np-site-pricing--soft .np-site-plan__feat { border-top-color: rgba(127, 140, 160, .22); }
.np-site-plan__feat li {
  position: relative;
  padding: 4px 0 4px 20px;
  font-size: 12px;
  line-height: 1.6;
  color: var(--np-text-2);
}
.np-site-plan__feat li::before {
  content: "\2713";
  position: absolute;
  left: 2px;
  top: 4px;
  font-size: 12px;
  font-weight: 700;
  color: var(--sp-tint-ink);
}
.np-site-plan__btn {
  display: block;
  width: 100%;
  margin-top: auto;
  padding: 8px 10px;
  font-size: 13px;
  font-weight: 600;
  text-align: center;
  text-decoration: none;
  color: #fff;
  background: var(--np-primary-dark, #135e96);
  border-radius: 20px;
  transition: opacity var(--np-transition);
}
.np-site-pricing--soft .np-site-plan__btn { color: var(--sp-tint-ink); background: var(--np-bg); }
.np-site-plan__btn:hover { opacity: .86; }

/* 45.3 NP 热门榜单 -------------------------------------------------------- */
.np-site-rank { position: relative; }
.np-site-rank__radio {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}
.np-site-rank__tab {
  display: inline-block;
  margin: 0 6px 10px 0;
  padding: 5px 13px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  color: var(--np-text-2);
  background: var(--np-bg-soft);
  border: 1px solid var(--np-line);
  border-radius: 20px;
  transition: color var(--np-transition), background var(--np-transition);
}
.np-site-rank__tab:hover { color: var(--np-primary-dark, #135e96); }
.np-site-rank__panel { display: none; }
.np-site-rank__r0:checked ~ .np-site-rank__tab[data-i="0"] {
  color: #fff;
  border-color: var(--np-primary-dark, #135e96);
  background: var(--np-primary-dark, #135e96);
}
.np-site-rank__r0:checked ~ .np-site-rank__panel[data-i="0"] { display: block; }
.np-site-rank__r1:checked ~ .np-site-rank__tab[data-i="1"] {
  color: #fff;
  border-color: var(--np-primary-dark, #135e96);
  background: var(--np-primary-dark, #135e96);
}
.np-site-rank__r1:checked ~ .np-site-rank__panel[data-i="1"] { display: block; }
.np-site-rank__r2:checked ~ .np-site-rank__tab[data-i="2"] {
  color: #fff;
  border-color: var(--np-primary-dark, #135e96);
  background: var(--np-primary-dark, #135e96);
}
.np-site-rank__r2:checked ~ .np-site-rank__panel[data-i="2"] { display: block; }
.np-site-rank__r3:checked ~ .np-site-rank__tab[data-i="3"] {
  color: #fff;
  border-color: var(--np-primary-dark, #135e96);
  background: var(--np-primary-dark, #135e96);
}
.np-site-rank__r3:checked ~ .np-site-rank__panel[data-i="3"] { display: block; }
.np-site-rank__list { margin: 0; padding: 0; list-style: none; }
.np-site-rank__item {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  padding: 6px 0;
  border-bottom: 1px dashed var(--np-line);
}
.np-site-rank__item:last-child { border-bottom: 0; }
.np-site-rank__num {
  flex: 0 0 18px;
  height: 18px;
  font-size: 11px;
  font-weight: 700;
  line-height: 18px;
  text-align: center;
  color: var(--np-text-2);
  background: var(--np-bg-soft);
  border-radius: 4px;
}
.np-site-rank__item.is-top .np-site-rank__num { color: #fff; background: var(--np-primary-dark, #135e96); }
.np-site-rank__title {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 13px;
  color: var(--np-text);
  text-decoration: none;
}
a.np-site-rank__title:hover { color: var(--np-primary-dark, #135e96); }
.np-site-rank__val {
  flex: 0 0 auto;
  font-size: 11px;
  color: var(--np-text-2);
  font-variant-numeric: tabular-nums;
}

/* 45.4 NP 专题合集 -------------------------------------------------------- */
.np-site-series {
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
  overflow: hidden;
  background: var(--np-bg);
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
}
.np-site-series__cover {
  position: relative;
  min-height: 190px;
  overflow: hidden;
  background: var(--np-bg-soft);
}
.np-site-series__cover img { display: block; width: 100%; height: 100%; object-fit: cover; }
.np-site-series__label {
  position: absolute;
  left: 10px;
  top: 10px;
  padding: 3px 10px;
  font-size: 11px;
  color: var(--np-text-2);
  background: var(--np-bg);
  border-radius: 5px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, .10);
}
.np-site-series__body { min-width: 0; padding: 16px 18px; }
.np-site-series__head {
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--np-line);
}
.np-site-series__name {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 17px;
  font-weight: 700;
  color: var(--np-text);
}
.np-site-series__more {
  flex: 0 0 auto;
  font-size: 12px;
  color: var(--np-primary-dark, #135e96);
  text-decoration: none;
}
.np-site-series__more:hover { text-decoration: underline; }
.np-site-series__list { margin: 8px 0 0; padding: 0; list-style: none; }
.np-site-series__list li {
  position: relative;
  padding: 5px 0 5px 14px;
  font-size: 13px;
  color: var(--np-text-2);
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.np-site-series__list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 12px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--np-primary-dark, #135e96);
}
.np-site-series__list a { color: var(--np-text-2); text-decoration: none; }
.np-site-series__list a:hover { color: var(--np-primary-dark, #135e96); }

/* 45.5 NP 双语服务卡 ------------------------------------------------------ */
.np-site-service__en {
  margin: 0 0 12px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .18em;
  color: var(--np-primary-dark, #135e96);
}
.np-site-service {
  display: grid;
  grid-template-columns: repeat(var(--np-wx-cols, 4), minmax(0, 1fr));
  gap: 14px;
}
.np-site-sitem {
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 18px 16px;
  text-decoration: none;
  color: var(--np-text);
  background: var(--np-bg);
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  transition: transform var(--np-transition), border-color var(--np-transition), box-shadow var(--np-transition);
}
.np-site-service--plain .np-site-sitem { border: 0; border-bottom: 1px solid var(--np-line); border-radius: 0; background: transparent; }
a.np-site-sitem:hover {
  transform: translateY(-2px);
  border-color: var(--np-primary-dark, #135e96);
  box-shadow: var(--np-shadow);
}
.np-site-service--plain a.np-site-sitem:hover { transform: none; box-shadow: none; }
.np-site-sitem__top { display: block; margin-bottom: 12px; }
.np-site-sitem__no {
  display: inline-block;
  font-size: 20px;
  font-weight: 800;
  letter-spacing: .04em;
  color: var(--np-primary-dark, #135e96);
  opacity: .8;
}
.np-site-sitem__title { font-size: 15px; font-weight: 600; line-height: 1.5; color: var(--np-text); }
.np-site-sitem__sub {
  margin-top: 3px;
  font-size: 11px;
  line-height: 1.5;
  letter-spacing: .02em;
  color: var(--np-primary-dark, #135e96);
}
.np-site-sitem__desc { margin-top: 9px; font-size: 12px; line-height: 1.7; color: var(--np-text-2); }

/* 45.6 NP 联系我们 -------------------------------------------------------- */
.np-site-contact__rows { margin: 0 0 12px; padding: 0; list-style: none; }
.np-site-contact__rows li {
  display: flex;
  gap: 10px;
  padding: 6px 0;
  font-size: 13px;
  border-bottom: 1px dashed var(--np-line);
}
.np-site-contact__rows li:last-child { border-bottom: 0; }
.np-site-contact__k { flex: 0 0 42px; color: var(--np-text-2); }
.np-site-contact__v { flex: 1 1 auto; min-width: 0; word-break: break-word; color: var(--np-text); }
.np-site-contact__qrs { display: flex; gap: 10px; margin: 12px 0; }
.np-site-contact__qr { flex: 1 1 0; min-width: 0; margin: 0; text-align: center; }
.np-site-contact__qr img,
.np-site-contact__qrph {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  font-size: 11px;
  color: var(--np-text-2);
  background: var(--np-bg-soft);
  border: 1px dashed var(--np-line);
  border-radius: var(--np-radius-sm);
}
.np-site-contact__qr figcaption { margin-top: 6px; font-size: 11px; line-height: 1.5; color: var(--np-text-2); }
.np-site-contact__btn {
  display: block;
  padding: 9px 12px;
  font-size: 13px;
  font-weight: 600;
  text-align: center;
  text-decoration: none;
  color: #fff;
  background: var(--np-primary-dark, #135e96);
  border-radius: var(--np-radius-sm);
}
.np-site-contact__btn:hover { opacity: .88; }

/* 45.7 双端适配：平板两列、手机一列，侧栏一律紧凑 ----------------------- */
@media (max-width: 960px) {
  .np-site-cards,
  .np-site-pricing,
  .np-site-service { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .np-site-series { grid-template-columns: 1fr; }
  .np-site-series__cover { min-height: 150px; }
}
@media (max-width: 640px) {
  .np-site-cards,
  .np-site-pricing,
  .np-site-service { grid-template-columns: 1fr; gap: 10px; }
  .np-site-card__media { aspect-ratio: 16 / 8; }
  .np-site-plan { padding: 16px 14px; }
  .np-site-plan__price b { font-size: 24px; }
  .np-site-series__body { padding: 12px 14px; }
  .np-site-rank__tab { margin-right: 5px; padding: 5px 10px; }
}
/* 全宽小工具误投侧栏：第 41 章已把 --np-wx-cols 降为 1，这里补紧凑排版 */
.np-sidebar-col .np-site-card__title,
.np-wa[data-np-wide="0"] .np-site-card__title { min-height: 0; }
.np-sidebar-col .np-site-plan__feat li,
.np-wa[data-np-wide="0"] .np-site-plan__feat li { padding-top: 3px; padding-bottom: 3px; }

@media (prefers-reduced-motion: reduce) {
  .np-site-card,
  .np-site-plan,
  .np-site-sitem,
  .np-site-rank__tab,
  .np-site-plan__btn { transition: none; }
  a.np-site-card:hover,
  .np-site-plan:hover,
  a.np-site-sitem:hover { transform: none; }
}


/* 45.8 暗色对比度：深主色只做背景，文字统一换成亮主色 --------------------
   body.np-dark 只覆盖 --np-primary（亮蓝），--np-primary-dark 仍是深蓝，
   拿它当文字色压在深底上只有 2~3:1。这里把 45 章里所有「强调文字」在
   暗色下切到 --np-primary，强调底仍是深蓝 + 白字（≥7:1）。 */
body.np-dark .np-site-icon,
body.np-dark .np-site-card__cat,
body.np-dark .np-site-rank__tab:hover,
body.np-dark a.np-site-rank__title:hover,
body.np-dark .np-site-series__more,
body.np-dark .np-site-series__list a:hover,
body.np-dark .np-site-service__en,
body.np-dark .np-site-sitem__no,
body.np-dark .np-site-sitem__sub,
body.np-dark a.np-site-sitem:hover .np-site-sitem__no,
body.np-dark .np-site-plan__icon,
body.np-dark .np-site-plan__feat li::before {
  color: var(--np-primary, #4f9ce8);
}
body.np-dark .np-site-pricing--soft .np-site-plan__btn {
  color: #fff;
  background: var(--np-primary-dark, #135e96);
}


/* ==========================================================================
   46. 1.8.58 内容增强与手机端遮挡修复
   --------------------------------------------------------------------------
   本轮移除前台「页面设置」浮标（原 40.5 的 fixed 胶囊按钮压住手机底部导航），
   并参考主流资讯 / 资源站补上四项内容能力：顶部阅读进度条、正文图片灯箱、
   代码块一键复制、深色模式跟随系统，以及文末版权声明卡。
   规则只命中 .np-ce-* 新元素与下面明确标注的手机修复，既有页面零变化。
   颜色全部走 --np-* 设计令牌，亮 / 暗色与四套页面样式自动跟随。
   ========================================================================== */

/* 46.1 阅读进度条：只在存在 .np-entry 的单篇页由 JS 动态插入 */
.np-ce-progress {
  position: fixed; top: 0; left: 0; right: 0; height: 3px; z-index: 9999;
  background: transparent; pointer-events: none; opacity: 0;
  transition: opacity .25s ease;
}
.np-ce-progress.is-visible { opacity: 1; }
.np-ce-progress i {
  display: block; height: 100%; width: 0;
  background: var(--np-primary, #2271d1);
  box-shadow: 0 0 6px rgba(34, 113, 209, .45);
  transition: width .08s linear;
}

/* 46.2 代码块一键复制：position 只加在 JS 标记过的 pre 上 */
.np-entry pre.np-ce-has-copy { position: relative; }
.np-ce-zoomable { cursor: zoom-in; }
.np-ce-zoomable:focus-visible { outline: 2px solid var(--np-primary, #2271d1); outline-offset: 2px; }
.np-ce-copy {
  position: absolute; top: 8px; right: 8px; z-index: 2;
  border: 1px solid var(--np-line, #e3e8ef); border-radius: 6px;
  background: var(--np-bg, #fff); color: var(--np-text, #1f2937);
  padding: 4px 9px; font-size: 11.5px; line-height: 1.4; cursor: pointer;
  opacity: .72; transition: opacity .18s, color .18s, border-color .18s, background .18s;
}
.np-entry pre:hover .np-ce-copy,
.np-ce-copy:focus-visible { opacity: 1; }
.np-ce-copy:hover { border-color: var(--np-primary, #2271d1); color: var(--np-primary, #2271d1); }
.np-ce-copy.is-ok { color: #fff; background: #2f7a5b; border-color: #2f7a5b; opacity: 1; }
.np-ce-copy.is-err { color: #fff; background: #b33636; border-color: #b33636; opacity: 1; }

/* 46.3 正文图片灯箱 */
.np-ce-lightbox { position: fixed; inset: 0; z-index: 10000; display: flex; align-items: center; justify-content: center; }
.np-ce-lightbox__mask { position: absolute; inset: 0; background: rgba(10, 14, 22, .92); }
body.np-dark .np-ce-lightbox__mask { background: rgba(5, 8, 14, .95); }
.np-ce-lightbox__view {
  position: relative; z-index: 1; max-width: 88vw; max-height: 84vh;
  display: flex; align-items: center; justify-content: center; cursor: zoom-out;
}
.np-ce-lightbox__view img {
  max-width: 88vw; max-height: 84vh; width: auto; height: auto; object-fit: contain;
  border-radius: 6px; box-shadow: 0 18px 60px rgba(0, 0, 0, .5);
}
.np-ce-lightbox__close,
.np-ce-lightbox__nav {
  position: absolute; z-index: 2; border: 0; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  background: rgba(255, 255, 255, .14); color: #fff; border-radius: 999px;
  transition: background .18s;
}
.np-ce-lightbox__close { top: 16px; right: 18px; width: 44px; height: 44px; font-size: 28px; line-height: 1; }
.np-ce-lightbox__nav { top: 50%; transform: translateY(-50%); width: 46px; height: 46px; font-size: 30px; line-height: 1; }
.np-ce-lightbox__prev { left: 16px; }
.np-ce-lightbox__next { right: 16px; }
.np-ce-lightbox__nav:disabled { opacity: .28; cursor: default; }
.np-ce-lightbox__close:hover,
.np-ce-lightbox__nav:not(:disabled):hover { background: rgba(255, 255, 255, .28); }
.np-ce-lightbox__count {
  position: absolute; z-index: 2; bottom: 22px; left: 50%; transform: translateX(-50%);
  color: #fff; font-size: 12.5px; border-radius: 999px; padding: 5px 14px;
  background: rgba(0, 0, 0, .42);
}

/* 46.4 文末版权声明卡 */
.np-ce-copyright {
  display: flex; align-items: flex-start; flex-wrap: wrap; gap: 13px;
  margin: 26px 0 8px; padding: 16px 18px;
  border: 1px solid var(--np-line, #e3e8ef);
  border-left: 3px solid var(--np-primary, #2271d1);
  border-radius: var(--np-radius, 10px);
  background: var(--np-bg-soft, #f6f9fd); color: var(--np-text, #1f2937);
}
.np-ce-copyright__icon {
  flex: 0 0 34px; width: 34px; height: 34px; border-radius: 9px;
  display: flex; align-items: center; justify-content: center;
  background: var(--np-primary, #2271d1); color: #fff;
}
.np-ce-copyright__main { flex: 1 1 260px; min-width: 0; }
.np-ce-copyright__title { font-size: 13.5px; font-weight: 800; margin-bottom: 5px; }
.np-ce-copyright__text {
  margin: 0 0 8px; font-size: 12.5px; line-height: 1.75;
  color: var(--np-text-2, #4b5563);
}
.np-ce-copyright__link { display: flex; align-items: baseline; gap: 8px; font-size: 11.5px; min-width: 0; }
.np-ce-copyright__link > span { flex: 0 0 auto; color: var(--np-text-2, #4b5563); }
.np-ce-copyright__link a {
  color: var(--np-primary, #2271d1); text-decoration: none;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.np-ce-copyright__link a:hover { text-decoration: underline; }
.np-ce-copyright__copy {
  flex: 0 0 auto; align-self: center;
  display: inline-flex; align-items: center; gap: 5px;
  border: 1px solid var(--np-line, #e3e8ef); border-radius: 8px;
  background: var(--np-bg, #fff); color: var(--np-text, #1f2937);
  padding: 8px 12px; font-size: 12px; cursor: pointer;
  transition: border-color .18s, color .18s, background .18s;
}
.np-ce-copyright__copy:hover { border-color: var(--np-primary, #2271d1); color: var(--np-primary, #2271d1); }
.np-ce-copyright__copy.is-ok { color: #fff; background: #2f7a5b; border-color: #2f7a5b; }
.np-ce-copyright__copy.is-err { color: #fff; background: #b33636; border-color: #b33636; }

/* 46.5 手机端：修被快捷工具圆形钮压住的标题、给新组件做窄屏适配 */
@media (max-width: 720px) {
  /* 「常用服务」标题栏原本右侧贴着 fixed 的快捷工具展开钮，
     副标题「本站功能一屏直达」被圆钮压住、文字被截断；这里留出 54px
     安全区并让副标题独占一行，工具条仍能正常展开，不再互相遮挡。 */
  .np-uc__block-head { padding-right: 54px; flex-wrap: wrap; gap: 4px 10px; }
  .np-uc__block-head .np-uc__block-tip { flex: 1 1 100%; font-size: 11px; line-height: 1.4; }

  .np-ce-progress { height: 2px; }
  .np-ce-copy { opacity: 1; padding: 5px 10px; }
  .np-ce-copyright { padding: 14px; gap: 10px; margin-top: 20px; }
  .np-ce-copyright__icon { display: none; }
  .np-ce-copyright__copy { width: 100%; justify-content: center; margin-top: 4px; }
  .np-ce-lightbox__close { top: 10px; right: 10px; }
  .np-ce-lightbox__nav { width: 44px; height: 44px; }
  .np-ce-lightbox__prev { left: 6px; }
  .np-ce-lightbox__next { right: 6px; }
  .np-ce-lightbox__view,
  .np-ce-lightbox__view img { max-width: 94vw; max-height: 80vh; }
}

/* ==========================================================================
   47. 1.8.59 页面样式方案：新增 4 套（报刊头条 / 影像画廊 / 时光日志 / 星云科技）
   --------------------------------------------------------------------------
   与第 42 章同样的约定，保证 1~46 章与既有 4 套方案逐字节不变：

   - 所有规则以 body.np-preset-{newsprint|gallery|timeline|nebula} 开头，
     magazine / cards / reading / shop 与 *-default 一条都不命中；
   - 只改外观（颜色 / 圆角 / 阴影 / 间距 / 字排 / 背景），不动 DOM 与布局；
   - 颜色尽量走 --np-* 设计令牌：newspress_style_css() 会在亮 / 暗色下各
     输出一套令牌，方案因此自动跟随页面明暗与主题设置，不必硬编码两套；
   - 方案私有变量统一用 --sp-*（字体栈、装饰色、氛围渐变、阴影），
     避免与内联输出的 --np-* 层叠冲突；
   - 顶栏品牌白字一律带 .np-header 限定，导航文字配色一律收进
     @media (min-width:961px)，手机端抽屉保持主题默认的深色可读文字；
   - 手机三档降列（1100 / 900 / 560），列数由 --np-cols 驱动，抵消主题
     960 / 640 断点对 .np-post-grid 的直接覆盖；
   - 暗色用 body.np-dark.np-preset-* 覆盖氛围层，文字对比度 ≥4.5:1；
   - 尊重 prefers-reduced-motion。
   ========================================================================== */

/* --------------------------------------------------------------------------
   47.0 公共接入：把 4 套新方案并入此前各章为三套方案建立的通用机制
   -------------------------------------------------------------------------- */

/* 47.0.1 列数令牌驱动（对齐 42.0）。timeline 是 list=text，第 40 章已有
   强制单列声明，不需要也不应再覆盖它的 grid-template-columns。 */
body.np-preset-newsprint .np-post-grid,
body.np-preset-gallery .np-post-grid,
body.np-preset-nebula .np-post-grid {
  grid-template-columns: repeat(var(--np-cols, 3), minmax(0, 1fr));
}

/* 47.0.2 深色主色兜底（对齐 42.0.1）：即使内联样式未加载，hover 也不会
   回退成资讯杂志的蓝色。内联令牌输出时优先级更高，会自然覆盖这里。 */
body.np-preset-newsprint { --np-primary-dark: #8c1f24; }
body.np-preset-gallery   { --np-primary-dark: #8e4f0a; }
body.np-preset-timeline  { --np-primary-dark: #173bb0; }
body.np-preset-nebula    { --np-primary-dark: #3d35c4; }

/* 47.0.3 明暗切换状态反馈（对齐 44.0）：暗色下月亮 -> 太阳。 */
body.np-dark.np-preset-newsprint .np-dark-toggle__icon--sun,
body.np-dark.np-preset-gallery .np-dark-toggle__icon--sun,
body.np-dark.np-preset-timeline .np-dark-toggle__icon--sun,
body.np-dark.np-preset-nebula .np-dark-toggle__icon--sun { display: block; }
body.np-dark.np-preset-newsprint .np-dark-toggle__icon--moon,
body.np-dark.np-preset-gallery .np-dark-toggle__icon--moon,
body.np-dark.np-preset-timeline .np-dark-toggle__icon--moon,
body.np-dark.np-preset-nebula .np-dark-toggle__icon--moon { display: none; }

/* 47.0.4 快捷工具条里的图标按钮（对齐 44.1 / 44.2）。手机端头部按钮隐藏，
   工具条这一个是唯一入口，必须保持 40px 与令牌配色、暗色金色高亮。 */
body.np-preset-newsprint .np-side-tools .np-search-toggle,
body.np-preset-newsprint .np-side-tools .np-dark-toggle,
body.np-preset-newsprint .np-side-tools .np-translate-toggle,
body.np-preset-gallery .np-side-tools .np-search-toggle,
body.np-preset-gallery .np-side-tools .np-dark-toggle,
body.np-preset-gallery .np-side-tools .np-translate-toggle,
body.np-preset-timeline .np-side-tools .np-search-toggle,
body.np-preset-timeline .np-side-tools .np-dark-toggle,
body.np-preset-timeline .np-side-tools .np-translate-toggle,
body.np-preset-nebula .np-side-tools .np-search-toggle,
body.np-preset-nebula .np-side-tools .np-dark-toggle,
body.np-preset-nebula .np-side-tools .np-translate-toggle {
  width: 40px;
  height: 40px;
  border: 1px solid var(--np-line);
  border-radius: 10px;
  background: var(--np-bg);
  color: var(--np-text-2);
}
body.np-preset-newsprint .np-side-tools .np-search-toggle:hover,
body.np-preset-newsprint .np-side-tools .np-dark-toggle:hover,
body.np-preset-newsprint .np-side-tools .np-translate-toggle:hover,
body.np-preset-gallery .np-side-tools .np-search-toggle:hover,
body.np-preset-gallery .np-side-tools .np-dark-toggle:hover,
body.np-preset-gallery .np-side-tools .np-translate-toggle:hover,
body.np-preset-timeline .np-side-tools .np-search-toggle:hover,
body.np-preset-timeline .np-side-tools .np-dark-toggle:hover,
body.np-preset-timeline .np-side-tools .np-translate-toggle:hover,
body.np-preset-nebula .np-side-tools .np-search-toggle:hover,
body.np-preset-nebula .np-side-tools .np-dark-toggle:hover,
body.np-preset-nebula .np-side-tools .np-translate-toggle:hover {
  color: var(--np-primary);
  border-color: var(--np-primary);
  background: var(--np-primary-soft);
}
body.np-dark.np-preset-newsprint .np-side-tools .np-dark-toggle,
body.np-dark.np-preset-gallery .np-side-tools .np-dark-toggle,
body.np-dark.np-preset-timeline .np-side-tools .np-dark-toggle,
body.np-dark.np-preset-nebula .np-side-tools .np-dark-toggle {
  color: #f5d76e;
  border-color: rgba(245, 215, 110, .42);
  background: rgba(245, 215, 110, .10);
}

/* 47.0.5 轮播占位底（对齐 43.3）：首图未加载完时不露主题的黑带。 */
body.np-preset-newsprint .np-slider { background: #f4efe4; }
body.np-preset-gallery .np-slider   { background: #e8e7e3; }
body.np-preset-timeline .np-slider  { background: #eaf0ff; }
body.np-preset-nebula .np-slider    { background: #e9ecff; }
body.np-dark.np-preset-newsprint .np-slider { background: #232019; }
body.np-dark.np-preset-gallery .np-slider   { background: #1b1e22; }
body.np-dark.np-preset-timeline .np-slider  { background: #1b2130; }
body.np-dark.np-preset-nebula .np-slider    { background: #181b2e; }

/* 47.0.6 手机抽屉「当前语言」对比度（对齐 43.4）：统一用深主色。 */
@media (max-width: 960px) {
  body.np-preset-newsprint .np-nav .np-translate-menu__item.is-active,
  body.np-preset-gallery .np-nav .np-translate-menu__item.is-active,
  body.np-preset-timeline .np-nav .np-translate-menu__item.is-active,
  body.np-preset-nebula .np-nav .np-translate-menu__item.is-active,
  body.np-preset-newsprint .np-nav .np-translate-menu__item.is-active em,
  body.np-preset-gallery .np-nav .np-translate-menu__item.is-active em,
  body.np-preset-timeline .np-nav .np-translate-menu__item.is-active em,
  body.np-preset-nebula .np-nav .np-translate-menu__item.is-active em {
    color: var(--np-primary-dark, var(--np-text));
  }
}


/* ==========================================================================
   47.1 报刊头条 newsprint
   --------------------------------------------------------------------------
   衬线大标题、细线分栏、红色印章色。像一份摊开的宽幅报纸：留白足、线多、
   几乎没有圆角与阴影，靠字重与分栏线建立层级。
   ========================================================================== */

/* A. 氛围与私有变量 */
body.np-preset-newsprint {
  --sp-serif: Georgia, "Times New Roman", "Songti SC", "Noto Serif CJK SC", "Source Han Serif SC", "SimSun", serif;
  --sp-ink: var(--np-text);
  --sp-sub: var(--np-text-2);
  --sp-line: var(--np-line);
  --sp-paper: var(--np-bg);
  --sp-soft: var(--np-bg-soft);
  --sp-red: var(--np-primary);
  --sp-red-dark: var(--np-primary-dark);
  --sp-shadow: none;
  background-color: var(--sp-paper);
  color: var(--sp-ink);
}
body.np-preset-newsprint .np-main { background: transparent; }

/* B. 顶栏：米白纸 + 上下双线，品牌衬线粗体 */
body.np-preset-newsprint .np-header {
  background: var(--sp-paper);
  border-bottom: 3px double var(--sp-ink);
  box-shadow: none;
}
body.np-preset-newsprint .np-header .np-brand__title,
body.np-preset-newsprint .np-header .np-brand__name {
  font-family: var(--sp-serif);
  font-weight: 800;
  letter-spacing: 1.2px;
  color: var(--sp-ink);
}
body.np-preset-newsprint .np-header .np-brand__tagline { color: var(--sp-sub); }
body.np-preset-newsprint .np-header .np-search-toggle,
body.np-preset-newsprint .np-header .np-dark-toggle,
body.np-preset-newsprint .np-header .np-translate-toggle {
  border-color: var(--sp-line);
  border-radius: 2px;
  color: var(--sp-sub);
  background: transparent;
}
body.np-preset-newsprint .np-header .np-search-toggle:hover,
body.np-preset-newsprint .np-header .np-dark-toggle:hover,
body.np-preset-newsprint .np-header .np-translate-toggle:hover {
  color: var(--sp-red);
  border-color: var(--sp-red);
}

/* C. 桌面导航：仅在桌面生效，手机抽屉保持默认可读文字 */
@media (min-width: 961px) {
  body.np-preset-newsprint .np-nav a {
    font-family: var(--sp-serif);
    font-size: 15px;
    font-weight: 700;
    letter-spacing: .4px;
    color: var(--sp-ink);
    border-radius: 0;
    padding: 8px 12px;
  }
  body.np-preset-newsprint .np-nav a:hover,
  body.np-preset-newsprint .np-nav .current-menu-item > a,
  body.np-preset-newsprint .np-nav .current-menu-ancestor > a {
    color: var(--sp-paper);
    background: var(--sp-ink);
  }
  body.np-preset-newsprint .np-nav ul ul {
    border: 1px solid var(--sp-ink);
    border-radius: 0;
    box-shadow: 4px 4px 0 var(--sp-soft);
    background: var(--sp-paper);
  }
  body.np-preset-newsprint .np-nav ul ul a { color: var(--sp-ink); border-radius: 0; }
}

/* D. 模块标题：红色栏目条 + 衬线大字 + 下方双线 */
body.np-preset-newsprint .np-module { margin-bottom: 30px; }
body.np-preset-newsprint .np-module__head {
  border-bottom: 3px double var(--sp-line);
  padding-bottom: 9px;
  margin-bottom: 16px;
}
body.np-preset-newsprint .np-module__title {
  font-family: var(--sp-serif);
  font-size: 24px;
  font-weight: 800;
  letter-spacing: .2px;
  color: var(--sp-ink);
}
body.np-preset-newsprint .np-module__title::before {
  width: 5px; height: 22px; border-radius: 0;
  background: var(--sp-red);
}
body.np-preset-newsprint .np-module__more {
  font-family: var(--sp-serif);
  color: var(--sp-red-dark);
  font-weight: 700;
  border-bottom: 1px solid var(--sp-red);
  border-radius: 0;
  padding: 2px 0;
  background: transparent;
}
body.np-preset-newsprint .np-module__more:hover { color: var(--sp-ink); border-bottom-color: var(--sp-ink); }
body.np-preset-newsprint .np-breadcrumb,
body.np-preset-newsprint .np-crumb { color: var(--sp-sub); font-size: 12.5px; }
body.np-preset-newsprint .np-breadcrumb b,
body.np-preset-newsprint .np-crumb b { color: var(--sp-red-dark); }

/* E. 卡片 / 列表：细线直角、无阴影，标题与摘要走报纸字排 */
body.np-preset-newsprint .np-post-grid { gap: 0 22px; }
body.np-preset-newsprint .np-card {
  border: 1px solid var(--sp-line);
  border-radius: 0;
  box-shadow: none;
  background: var(--sp-paper);
}
body.np-preset-newsprint .np-card:hover { border-color: var(--sp-red); }
body.np-preset-newsprint .np-card__thumb { border-radius: 0; aspect-ratio: 16 / 9; }
body.np-preset-newsprint .np-card__body { padding: 14px 16px 16px; }
body.np-preset-newsprint .np-card__title {
  font-family: var(--sp-serif);
  font-size: 19px;
  font-weight: 800;
  line-height: 1.42;
  letter-spacing: .1px;
}
body.np-preset-newsprint .np-card__title a { color: var(--sp-ink); }
body.np-preset-newsprint .np-card:hover .np-card__title a { color: var(--sp-red-dark); }
body.np-preset-newsprint .np-card__body > p { color: var(--sp-sub); line-height: 1.75; font-size: 13.5px; }
body.np-preset-newsprint .np-post-meta {
  color: var(--sp-sub); font-size: 12px;
  border-top: 1px solid var(--sp-line); padding-top: 9px; margin-top: 8px;
}
body.np-preset-newsprint .np-post-item {
  border-bottom: 1px solid var(--sp-line);
  padding-bottom: 16px;
  gap: 18px;
}
body.np-preset-newsprint .np-post-item__thumb { border-radius: 0; }
body.np-preset-newsprint .np-post-item__title {
  font-family: var(--sp-serif); font-size: 19px; font-weight: 800; line-height: 1.45;
}
body.np-preset-newsprint .np-post-item__title a { color: var(--sp-ink); }
body.np-preset-newsprint .np-post-item:hover .np-post-item__title a { color: var(--sp-red-dark); }
body.np-preset-newsprint .np-post-item__excerpt { color: var(--sp-sub); line-height: 1.72; }

/* F. 按钮、小工具、页脚 */
body.np-preset-newsprint .np-btn--primary {
  border-radius: 0;
  background: var(--sp-red-dark);
  color: #fff;
  box-shadow: none;
  font-weight: 700;
}
body.np-preset-newsprint .np-btn--primary:hover { background: var(--sp-ink); }
body.np-preset-newsprint .np-widget {
  border: 1px solid var(--sp-line);
  border-radius: 0;
  background: var(--sp-paper);
  box-shadow: none;
  padding: 18px;
}
body.np-preset-newsprint .np-widget__title {
  font-family: var(--sp-serif);
  font-size: 17px;
  font-weight: 800;
  border-bottom: 2px solid var(--sp-ink);
  color: var(--sp-ink);
}
body.np-preset-newsprint .np-widget__title::before {
  width: 4px; height: 16px; border-radius: 0; background: var(--sp-red);
}
body.np-preset-newsprint .np-footer {
  border-top: 3px double var(--sp-ink);
  background: var(--sp-soft);
  color: var(--sp-sub);
}
body.np-preset-newsprint .np-side-tools[data-np-drag="all"] .np-side-tools__body {
  border-radius: 0;
  border: 1px solid var(--sp-line);
}

/* G. 文章页：衬线大标题、首字下沉、细线引用 */
body.np-preset-newsprint .np-single {
  border: 1px solid var(--sp-line);
  border-radius: 0;
  box-shadow: none;
  background: var(--sp-paper);
  padding: 30px 34px;
}
body.np-preset-newsprint .np-single__title {
  font-family: var(--sp-serif);
  font-size: clamp(28px, 3.6vw, 40px);
  font-weight: 800;
  letter-spacing: .2px;
  line-height: 1.32;
  color: var(--sp-ink);
}
body.np-preset-newsprint .np-single__meta { border-bottom: 1px solid var(--sp-ink); color: var(--sp-sub); }
body.np-preset-newsprint .np-single__cats a {
  border-radius: 0; border: 1px solid var(--sp-red);
  color: var(--sp-red-dark); background: transparent; padding: 2px 10px;
}
body.np-preset-newsprint .np-entry { font-size: 16.5px; line-height: 1.95; color: var(--sp-ink); }
body.np-preset-newsprint .np-entry > p:first-of-type::first-letter {
  float: left; font-family: var(--sp-serif); font-size: 58px; line-height: .9;
  font-weight: 800; color: var(--sp-red); padding: 4px 9px 0 0;
}
body.np-preset-newsprint .np-entry h2,
body.np-preset-newsprint .np-entry h3 {
  font-family: var(--sp-serif); font-weight: 800;
  border-left: 0; border-bottom: 1px solid var(--sp-line);
  padding: 0 0 7px; letter-spacing: .2px;
}
body.np-preset-newsprint .np-entry h2::before,
body.np-preset-newsprint .np-entry h3::before { display: none; }
body.np-preset-newsprint .np-entry blockquote {
  border-left: 3px solid var(--sp-red);
  border-radius: 0;
  background: var(--sp-soft);
  font-family: var(--sp-serif);
  font-style: italic;
  color: var(--sp-sub);
}
body.np-preset-newsprint .np-pa__act { border-radius: 0; }
body.np-preset-newsprint .np-pa__act.is-active { background: var(--sp-soft); color: var(--sp-red-dark); }

/* H. 暗色：装饰线转浅、印章红转亮，正文沿用暗色令牌 */
body.np-dark.np-preset-newsprint {
  background-color: var(--np-bg);
  background-image: radial-gradient(900px 420px at 4% -8%, rgba(176, 42, 48, .14), transparent 70%);
}
body.np-dark.np-preset-newsprint .np-header { border-bottom-color: var(--np-line); }
body.np-dark.np-preset-newsprint .np-header .np-brand__title,
body.np-dark.np-preset-newsprint .np-header .np-brand__name { color: var(--np-text); }
body.np-dark.np-preset-newsprint .np-module__title::before,
body.np-dark.np-preset-newsprint .np-widget__title::before { background: var(--np-primary); }
body.np-dark.np-preset-newsprint .np-btn--primary { background: var(--np-primary-dark); color: #fff; }
body.np-dark.np-preset-newsprint .np-footer { border-top-color: var(--np-line); background: var(--np-bg-soft); }


/* ==========================================================================
   47.2 影像画廊 gallery
   --------------------------------------------------------------------------
   墨黑顶栏 + 全出血大图卡，标题压在渐隐浮层上。图是主角，文字退到下方，
   用琥珀色做唯一强调。适合图集、素材、作品站。
   ========================================================================== */

/* A. 氛围与私有变量 */
body.np-preset-gallery {
  --sp-ink: var(--np-text);
  --sp-sub: var(--np-text-2);
  --sp-line: var(--np-line);
  --sp-surface: var(--np-bg);
  --sp-soft: var(--np-bg-soft);
  --sp-amber: var(--np-primary);
  --sp-amber-dark: var(--np-primary-dark);
  --sp-night: #15181f;
  --sp-night2: #242a35;
  --sp-mono: ui-monospace, "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  background-color: var(--sp-soft);
  color: var(--sp-ink);
}

/* B. 顶栏：墨黑渐变，白字品牌（限定 .np-header，不影响手机抽屉） */
body.np-preset-gallery .np-header {
  background: linear-gradient(100deg, var(--sp-night), var(--sp-night2));
  border-bottom: 1px solid rgba(255, 255, 255, .10);
  box-shadow: 0 6px 22px rgba(10, 12, 18, .16);
}
body.np-preset-gallery .np-header .np-brand__title,
body.np-preset-gallery .np-header .np-brand__name { color: #fff; letter-spacing: .6px; }
body.np-preset-gallery .np-header .np-brand__tagline { color: rgba(255, 255, 255, .66); }
body.np-preset-gallery .np-header .np-search-toggle,
body.np-preset-gallery .np-header .np-dark-toggle,
body.np-preset-gallery .np-header .np-translate-toggle {
  color: rgba(255, 255, 255, .88);
  border-color: rgba(255, 255, 255, .22);
  background: rgba(255, 255, 255, .07);
  border-radius: 6px;
}
body.np-preset-gallery .np-header .np-search-toggle:hover,
body.np-preset-gallery .np-header .np-dark-toggle:hover,
body.np-preset-gallery .np-header .np-translate-toggle:hover {
  color: #fff; border-color: var(--sp-amber); background: rgba(245, 180, 76, .18);
}

/* C. 桌面导航 */
@media (min-width: 961px) {
  body.np-preset-gallery .np-nav a {
    color: rgba(255, 255, 255, .82); font-size: 14px; font-weight: 600;
    letter-spacing: .3px; padding: 7px 13px; border-radius: 6px;
  }
  body.np-preset-gallery .np-nav a:hover,
  body.np-preset-gallery .np-nav .current-menu-item > a,
  body.np-preset-gallery .np-nav .current-menu-ancestor > a {
    color: var(--sp-night); background: var(--sp-amber);
  }
  body.np-preset-gallery .np-nav ul ul {
    background: var(--sp-night2); border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 8px; box-shadow: 0 16px 40px rgba(8, 10, 15, .34); padding: 8px;
  }
  body.np-preset-gallery .np-nav ul ul a { color: rgba(255, 255, 255, .88); border-radius: 5px; }
}

/* D. 模块标题：等宽小字 + 琥珀竖条 */
body.np-preset-gallery .np-module { margin-bottom: 32px; }
body.np-preset-gallery .np-module__head { border-bottom: 0; padding-bottom: 0; margin-bottom: 16px; }
body.np-preset-gallery .np-module__title {
  font-size: 19px; font-weight: 800; letter-spacing: 1.6px;
  text-transform: uppercase; color: var(--sp-ink);
}
body.np-preset-gallery .np-module__title::before {
  width: 4px; height: 20px; border-radius: 2px; background: var(--sp-amber);
}
body.np-preset-gallery .np-module__more {
  font-family: var(--sp-mono); font-size: 12px; letter-spacing: .5px;
  color: var(--sp-amber-dark); background: var(--sp-surface);
  border: 1px solid var(--sp-line); border-radius: 6px; padding: 6px 12px;
}
body.np-preset-gallery .np-module__more:hover { color: var(--sp-night); background: var(--sp-amber); border-color: var(--sp-amber); }
body.np-preset-gallery .np-breadcrumb,
body.np-preset-gallery .np-crumb { font-family: var(--sp-mono); color: var(--sp-sub); font-size: 11.5px; }

/* E. 卡片：全出血图 + 渐隐标题浮层（绝对定位，不改 DOM 也不撑高卡片） */
body.np-preset-gallery .np-post-grid { gap: 18px; }
body.np-preset-gallery .np-card {
  position: relative;
  overflow: hidden;
  border: 0;
  border-radius: 6px;
  background: var(--sp-night);
  box-shadow: 0 6px 20px rgba(16, 19, 25, .12);
  transition: transform 260ms cubic-bezier(.2, .8, .2, 1), box-shadow 260ms ease;
}
body.np-preset-gallery .np-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 16px 40px rgba(16, 19, 25, .26);
}
body.np-preset-gallery .np-card__thumb { aspect-ratio: 3 / 4; border-radius: 0; }
body.np-preset-gallery .np-card__thumb img { transition: transform 420ms ease; }
body.np-preset-gallery .np-card:hover .np-card__thumb img { transform: scale(1.045); }
body.np-preset-gallery .np-card__body {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 2;
  padding: 44px 14px 14px;
  background: linear-gradient(180deg, transparent, rgba(10, 12, 16, .82) 52%, rgba(10, 12, 16, .94));
  color: #fff;
}
body.np-preset-gallery .np-card__title {
  font-size: 16px; font-weight: 700; line-height: 1.45; margin-bottom: 6px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
body.np-preset-gallery .np-card__title a { color: #fff; }
body.np-preset-gallery .np-card:hover .np-card__title a { color: #ffd89b; }
body.np-preset-gallery .np-card__body > p { display: none; }
body.np-preset-gallery .np-post-meta {
  color: rgba(255, 255, 255, .76); font-size: 11.5px;
  border-top: 1px solid rgba(255, 255, 255, .18);
  padding-top: 8px; margin-top: 4px;
}
body.np-preset-gallery .np-post-meta::before { display: none; }
body.np-preset-gallery .np-post-meta a { color: rgba(255, 255, 255, .86); }
body.np-preset-gallery .np-post-item { border-bottom-color: var(--sp-line); padding-bottom: 18px; gap: 18px; }
body.np-preset-gallery .np-post-item__thumb { border-radius: 6px; aspect-ratio: 16 / 10; }
body.np-preset-gallery .np-post-item__title { font-weight: 700; letter-spacing: .2px; }
body.np-preset-gallery .np-post-item__title a { color: var(--sp-ink); }
body.np-preset-gallery .np-post-item:hover .np-post-item__title a { color: var(--sp-amber-dark); }

/* F. 按钮、小工具、页脚 */
body.np-preset-gallery .np-btn--primary {
  border-radius: 6px; background: var(--sp-amber-dark); color: #fff;
  box-shadow: none; font-weight: 700;
}
body.np-preset-gallery .np-btn--primary:hover { background: var(--sp-night); }
body.np-preset-gallery .np-widget {
  border: 1px solid var(--sp-line); border-radius: 6px;
  background: var(--sp-surface); box-shadow: none; padding: 18px;
}
body.np-preset-gallery .np-widget__title {
  font-size: 15px; font-weight: 800; letter-spacing: 1.1px; text-transform: uppercase;
  border-bottom-color: var(--sp-line);
}
body.np-preset-gallery .np-widget__title::before {
  width: 4px; height: 15px; border-radius: 2px; background: var(--sp-amber);
}
body.np-preset-gallery .np-footer {
  border-top: 0; background: var(--sp-night); color: rgba(255, 255, 255, .72);
}
body.np-preset-gallery .np-footer a { color: rgba(255, 255, 255, .86); }
body.np-preset-gallery .np-side-tools[data-np-drag="all"] .np-side-tools__body { border-radius: 8px; }

/* G. 文章页：封面式标题（方案 title=cover 已由第 40 章处理） */
body.np-preset-gallery .np-single {
  border: 0; border-radius: 8px; background: var(--sp-surface);
  box-shadow: 0 8px 30px rgba(16, 19, 25, .10); padding: 28px 32px;
}
body.np-preset-gallery .np-single__title { font-weight: 800; letter-spacing: -.3px; line-height: 1.36; }
body.np-preset-gallery .np-entry { font-size: 16px; line-height: 1.9; }
body.np-preset-gallery .np-entry h2,
body.np-preset-gallery .np-entry h3 { font-weight: 800; letter-spacing: .2px; }
body.np-preset-gallery .np-pa__act { border-radius: 6px; }
body.np-preset-gallery .np-pa__act.is-active { background: var(--np-primary-soft); color: var(--sp-amber-dark); }

/* H. 暗色：顶栏与页脚保持墨黑，卡片浮层不变，令牌自动切深 */
body.np-dark.np-preset-gallery { background-color: var(--np-bg); }
body.np-dark.np-preset-gallery .np-header { background: linear-gradient(100deg, #0e1015, #1a1e26); }
body.np-dark.np-preset-gallery .np-card { background: #0d1015; }
body.np-dark.np-preset-gallery .np-module__title::before,
body.np-dark.np-preset-gallery .np-widget__title::before { background: var(--np-primary); }
body.np-dark.np-preset-gallery .np-btn--primary { background: var(--np-primary-dark); color: #10131a; }
body.np-dark.np-preset-gallery .np-footer { background: #0e1015; }


/* ==========================================================================
   47.3 时光日志 timeline
   --------------------------------------------------------------------------
   左侧一条蓝色日期轴 + 圆点，单列窄栏、等宽日期标签。像一份持续更新的
   开发日志或连载博客，结构性极强，手机上也天然单列。
   ========================================================================== */

/* A. 氛围与私有变量（container 令牌已收窄到 820px） */
body.np-preset-timeline {
  --sp-ink: var(--np-text);
  --sp-sub: var(--np-text-2);
  --sp-line: var(--np-line);
  --sp-surface: var(--np-bg);
  --sp-soft: var(--np-bg-soft);
  --sp-blue: var(--np-primary);
  --sp-blue-dark: var(--np-primary-dark);
  --sp-mono: ui-monospace, "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  background-color: var(--sp-surface);
  color: var(--sp-ink);
}

/* B. 顶栏：白底 + 蓝色细下划线 + 蓝色圆点品牌 */
body.np-preset-timeline .np-header {
  background: var(--sp-surface);
  border-bottom: 2px solid var(--sp-blue);
  box-shadow: none;
}
body.np-preset-timeline .np-header .np-brand__title,
body.np-preset-timeline .np-header .np-brand__name { color: var(--sp-ink); font-weight: 800; letter-spacing: -.2px; }
body.np-preset-timeline .np-header .np-brand__tagline { color: var(--sp-sub); }
body.np-preset-timeline .np-header .np-search-toggle,
body.np-preset-timeline .np-header .np-dark-toggle,
body.np-preset-timeline .np-header .np-translate-toggle {
  border-color: var(--sp-line); border-radius: 8px; color: var(--sp-sub); background: var(--sp-soft);
}
body.np-preset-timeline .np-header .np-search-toggle:hover,
body.np-preset-timeline .np-header .np-dark-toggle:hover,
body.np-preset-timeline .np-header .np-translate-toggle:hover {
  color: var(--sp-blue-dark); border-color: var(--sp-blue); background: var(--np-primary-soft);
}

/* C. 桌面导航 */
@media (min-width: 961px) {
  body.np-preset-timeline .np-nav a {
    color: var(--sp-sub); font-size: 14px; font-weight: 600;
    padding: 7px 12px; border-radius: 8px;
  }
  body.np-preset-timeline .np-nav a:hover,
  body.np-preset-timeline .np-nav .current-menu-item > a,
  body.np-preset-timeline .np-nav .current-menu-ancestor > a {
    color: var(--sp-blue-dark); background: var(--np-primary-soft);
  }
  body.np-preset-timeline .np-nav ul ul {
    border: 1px solid var(--sp-line); border-radius: 10px;
    box-shadow: 0 14px 34px rgba(29, 78, 216, .14); background: var(--sp-surface);
  }
  body.np-preset-timeline .np-nav ul ul a { color: var(--sp-sub); border-radius: 6px; }
}

/* D. 模块标题：等宽日期感 + 蓝色圆点 */
body.np-preset-timeline .np-module { margin-bottom: 26px; }
body.np-preset-timeline .np-module__head { border-bottom: 1px solid var(--sp-line); padding-bottom: 10px; margin-bottom: 14px; }
body.np-preset-timeline .np-module__title {
  font-family: var(--sp-mono); font-size: 16px; font-weight: 700;
  letter-spacing: .6px; color: var(--sp-ink);
}
body.np-preset-timeline .np-module__title::before {
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--sp-blue); box-shadow: 0 0 0 3px var(--np-primary-soft);
}
body.np-preset-timeline .np-module__more {
  font-family: var(--sp-mono); font-size: 12px; color: var(--sp-blue-dark);
  background: var(--sp-soft); border-radius: 8px; padding: 5px 11px;
}
body.np-preset-timeline .np-module__more:hover { color: #fff; background: var(--sp-blue-dark); }
body.np-preset-timeline .np-breadcrumb,
body.np-preset-timeline .np-crumb { font-family: var(--sp-mono); color: var(--sp-sub); font-size: 11.5px; }

/* E. 日期轴：竖线 + 圆点，单列列表靠伪元素画出来，不改 DOM */
body.np-preset-timeline .np-post-list,
body.np-preset-timeline .np-post-grid {
  position: relative;
  padding-left: 26px;
  gap: 0;
}
body.np-preset-timeline .np-post-list::before,
body.np-preset-timeline .np-post-grid::before {
  content: ''; position: absolute; left: 6px; top: 6px; bottom: 10px;
  width: 3px; border-radius: 2px;
  background: var(--np-primary); opacity: .45;
}
body.np-preset-timeline .np-post-item {
  position: relative;
  overflow: visible;
  border-bottom: 1px solid var(--sp-line);
  border-radius: 0;
  padding: 6px 0 20px;
  gap: 16px;
}
body.np-preset-timeline .np-post-item::before {
  content: ''; position: absolute; left: -25px; top: 14px;
  width: 11px; height: 11px; border-radius: 50%;
  background: var(--sp-surface); border: 2.5px solid var(--sp-blue);
  box-shadow: 0 0 0 3px var(--sp-surface);
  z-index: 1;
}
body.np-preset-timeline .np-post-item:hover::before { background: var(--sp-blue); }
body.np-preset-timeline .np-post-item__thumb { border-radius: 8px; width: 132px; }
body.np-preset-timeline .np-post-item__title { font-size: 18px; font-weight: 700; line-height: 1.5; }
body.np-preset-timeline .np-post-item__title a { color: var(--sp-ink); }
body.np-preset-timeline .np-post-item:hover .np-post-item__title a { color: var(--sp-blue-dark); }
body.np-preset-timeline .np-post-item__excerpt { color: var(--sp-sub); line-height: 1.72; font-size: 13.5px; }
body.np-preset-timeline .np-post-meta {
  font-family: var(--sp-mono); font-size: 11.5px; letter-spacing: .2px;
  color: var(--sp-sub); gap: 10px;
}
body.np-preset-timeline .np-post-meta::before { display: none; }
/* 第 40 章 np-list-text 把卡片压成细线列表，这里补回一点呼吸感 */
body.np-preset-timeline .np-card { border-bottom: 1px solid var(--sp-line); padding: 4px 0 14px; }
body.np-preset-timeline .np-card__title { font-family: var(--sp-mono); font-size: 17px; font-weight: 700; }
body.np-preset-timeline .np-card__title a { color: var(--sp-ink); }
body.np-preset-timeline .np-card__body { padding: 4px 0 10px; }

/* E2. 单列日志条目：小图 + 文字横排。若沿用网格大图，一张卡就占满整屏，
   完全不像「日志」；改成 132px 缩略图 + 右侧文字，并补上轴上的圆点。 */
body.np-preset-timeline .np-card {
  position: relative;
  display: grid;
  grid-template-columns: 132px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
  padding: 10px 0 16px;
  /* 主题 .np-card 是 overflow:hidden，会把画在左外侧的轴点裁掉；
     卡片本身放开，改由缩略图自己裁圆角。 */
  overflow: visible;
}
body.np-preset-timeline .np-card::after {
  content: ''; position: absolute; left: -25px; top: 18px;
  width: 11px; height: 11px; border-radius: 50%;
  background: var(--sp-surface); border: 2.5px solid var(--sp-blue);
  box-shadow: 0 0 0 3px var(--sp-surface); z-index: 1;
}
body.np-preset-timeline .np-card:hover::after { background: var(--sp-blue); }
body.np-preset-timeline .np-card__thumb { aspect-ratio: 4 / 3; border-radius: 8px; overflow: hidden; }
body.np-preset-timeline .np-card__body { padding: 0; }
body.np-preset-timeline .np-card__body > p { font-size: 13px; line-height: 1.65; margin: 0 0 4px; }

/* F. 按钮、小工具、页脚 */
body.np-preset-timeline .np-btn--primary {
  border-radius: 8px; background: var(--sp-blue-dark); color: #fff;
  box-shadow: none; font-weight: 700;
}
body.np-preset-timeline .np-btn--primary:hover { background: var(--sp-ink); }
body.np-preset-timeline .np-widget {
  border: 1px solid var(--sp-line); border-radius: 10px;
  background: var(--sp-surface); box-shadow: none; padding: 18px;
}
body.np-preset-timeline .np-widget__title {
  font-family: var(--sp-mono); font-size: 14px; font-weight: 700; letter-spacing: .4px;
  border-bottom-color: var(--sp-line);
}
body.np-preset-timeline .np-widget__title::before {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--sp-blue); box-shadow: 0 0 0 3px var(--np-primary-soft);
}
body.np-preset-timeline .np-footer {
  border-top: 1px solid var(--sp-line); background: var(--sp-soft); color: var(--sp-sub);
}
body.np-preset-timeline .np-side-tools[data-np-drag="all"] .np-side-tools__body { border-radius: 10px; }

/* G. 文章页：蓝色小节线 + 等宽元信息 */
body.np-preset-timeline .np-single {
  border: 0; border-radius: 12px; box-shadow: none;
  background: var(--sp-surface); padding: 20px 0 0;
}
body.np-preset-timeline .np-single__title { font-size: clamp(26px, 3.4vw, 36px); font-weight: 800; letter-spacing: -.4px; line-height: 1.36; }
body.np-preset-timeline .np-single__meta { font-family: var(--sp-mono); font-size: 12px; color: var(--sp-sub); border-bottom-color: var(--sp-line); }
body.np-preset-timeline .np-single__cats a {
  border-radius: 8px; background: var(--np-primary-soft); color: var(--sp-blue-dark); font-family: var(--sp-mono);
}
body.np-preset-timeline .np-entry { font-size: 16px; line-height: 1.9; }
body.np-preset-timeline .np-entry h2,
body.np-preset-timeline .np-entry h3 {
  border-left: 3px solid var(--sp-blue); border-radius: 0;
  font-weight: 800; letter-spacing: -.2px; padding-left: 12px;
}
body.np-preset-timeline .np-entry blockquote {
  border-left: 3px solid var(--sp-blue); border-radius: 0 8px 8px 0;
  background: var(--sp-soft); color: var(--sp-sub);
}
body.np-preset-timeline .np-pa__act { border-radius: 8px; }
body.np-preset-timeline .np-pa__act.is-active { background: var(--np-primary-soft); color: var(--sp-blue-dark); }

/* H. 暗色 */
body.np-dark.np-preset-timeline { background-color: var(--np-bg); }
body.np-dark.np-preset-timeline .np-header { border-bottom-color: var(--np-line); }
body.np-dark.np-preset-timeline .np-header .np-brand__title,
body.np-dark.np-preset-timeline .np-header .np-brand__name { color: var(--np-text); }
body.np-dark.np-preset-timeline .np-post-item::before,
body.np-dark.np-preset-timeline .np-card::after,
body.np-dark.np-preset-timeline .np-widget__title::before { background: var(--np-bg); border-color: var(--np-primary); }
body.np-dark.np-preset-timeline .np-btn--primary { background: var(--np-primary-dark); color: #0d1120; }
body.np-dark.np-preset-timeline .np-footer { background: var(--np-bg-soft); }


/* ==========================================================================
   47.4 星云科技 nebula
   --------------------------------------------------------------------------
   深墨蓝渐变顶栏、青紫光晕、点阵背景、细发光边卡与等宽标签。信息密度高
   但不压抑，适合数码、AI、开发资源站。
   ========================================================================== */

/* A. 氛围与私有变量 */
body.np-preset-nebula {
  --sp-ink: var(--np-text);
  --sp-sub: var(--np-text-2);
  --sp-line: var(--np-line);
  --sp-surface: var(--np-bg);
  --sp-soft: var(--np-bg-soft);
  --sp-indigo: var(--np-primary);
  --sp-indigo-dark: var(--np-primary-dark);
  --sp-cyan: #0891b2;
  --sp-mono: ui-monospace, "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  --sp-glow: 0 0 0 1px rgba(79, 70, 229, .10), 0 8px 26px rgba(79, 70, 229, .10);
  --sp-glow-hi: 0 0 0 1px rgba(79, 70, 229, .28), 0 16px 44px rgba(79, 70, 229, .22);
  background-color: var(--sp-surface);
  background-image: radial-gradient(rgba(79, 70, 229, .075) 1px, transparent 1px);
  background-size: 18px 18px;
  color: var(--sp-ink);
}

/* B. 顶栏：深墨蓝 → 靛紫 → 青，白字品牌（限定 .np-header） */
body.np-preset-nebula .np-header {
  background: linear-gradient(100deg, #161a3a 0%, #2c2f78 48%, #3d35c4 78%, #0e7490 100%);
  border-bottom: 1px solid rgba(255, 255, 255, .14);
  box-shadow: 0 8px 28px rgba(24, 27, 78, .26);
}
body.np-preset-nebula .np-header .np-brand__title,
body.np-preset-nebula .np-header .np-brand__name { color: #fff; font-weight: 800; letter-spacing: .3px; }
body.np-preset-nebula .np-header .np-brand__tagline { color: rgba(255, 255, 255, .72); }
body.np-preset-nebula .np-header .np-search-toggle,
body.np-preset-nebula .np-header .np-dark-toggle,
body.np-preset-nebula .np-header .np-translate-toggle {
  color: rgba(255, 255, 255, .9);
  border-color: rgba(255, 255, 255, .26);
  background: rgba(255, 255, 255, .09);
  border-radius: 8px;
}
body.np-preset-nebula .np-header .np-search-toggle:hover,
body.np-preset-nebula .np-header .np-dark-toggle:hover,
body.np-preset-nebula .np-header .np-translate-toggle:hover {
  color: #fff; border-color: rgba(255, 255, 255, .7); background: rgba(255, 255, 255, .18);
}

/* C. 桌面导航 */
@media (min-width: 961px) {
  body.np-preset-nebula .np-nav a {
    color: rgba(255, 255, 255, .86); font-size: 14px; font-weight: 600;
    padding: 7px 13px; border-radius: 8px;
  }
  body.np-preset-nebula .np-nav a:hover,
  body.np-preset-nebula .np-nav .current-menu-item > a,
  body.np-preset-nebula .np-nav .current-menu-ancestor > a {
    color: #fff; background: rgba(255, 255, 255, .18);
    box-shadow: inset 0 -2px 0 rgba(34, 211, 238, .9);
  }
  body.np-preset-nebula .np-nav ul ul {
    background: #1b1e42; border: 1px solid rgba(255, 255, 255, .16);
    border-radius: 10px; box-shadow: 0 18px 44px rgba(14, 16, 46, .4); padding: 8px;
  }
  body.np-preset-nebula .np-nav ul ul a { color: rgba(255, 255, 255, .9); border-radius: 6px; }
}

/* D. 模块标题：等宽大写 + 青色小方块 */
body.np-preset-nebula .np-module { margin-bottom: 32px; }
body.np-preset-nebula .np-module__head { border-bottom: 0; padding-bottom: 0; margin-bottom: 16px; }
body.np-preset-nebula .np-module__title {
  font-family: var(--sp-mono); font-size: 17px; font-weight: 700;
  letter-spacing: 1.1px; text-transform: uppercase; color: var(--sp-ink);
}
body.np-preset-nebula .np-module__title::before {
  width: 10px; height: 10px; border-radius: 3px;
  background: linear-gradient(135deg, var(--sp-indigo), var(--sp-cyan));
  box-shadow: 0 0 10px rgba(79, 70, 229, .5);
}
body.np-preset-nebula .np-module__more {
  font-family: var(--sp-mono); font-size: 11.5px; letter-spacing: .4px;
  color: var(--sp-indigo-dark); background: var(--sp-surface);
  border: 1px solid var(--sp-line); border-radius: 999px; padding: 6px 13px;
}
body.np-preset-nebula .np-module__more:hover {
  color: #fff; background: var(--sp-indigo-dark); border-color: var(--sp-indigo-dark);
}
body.np-preset-nebula .np-breadcrumb,
body.np-preset-nebula .np-crumb { font-family: var(--sp-mono); color: var(--sp-sub); font-size: 11.5px; }
body.np-preset-nebula .np-breadcrumb b,
body.np-preset-nebula .np-crumb b { color: var(--sp-indigo-dark); }

/* E. 卡片：白底 + 细发光边 + 顶部彩条 */
body.np-preset-nebula .np-post-grid { gap: 18px; }
body.np-preset-nebula .np-card {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--sp-line);
  border-radius: 14px;
  background: var(--sp-surface);
  box-shadow: var(--sp-glow);
  transition: transform 240ms cubic-bezier(.2, .8, .2, 1), box-shadow 240ms ease;
}
body.np-preset-nebula .np-card::before {
  content: ''; position: absolute; left: 0; right: 0; top: 0; height: 3px; z-index: 2;
  background: linear-gradient(90deg, var(--sp-indigo), var(--sp-cyan), var(--sp-indigo));
  opacity: .82;
}
body.np-preset-nebula .np-card:hover { transform: translateY(-5px); box-shadow: var(--sp-glow-hi); }
body.np-preset-nebula .np-card__thumb { aspect-ratio: 16 / 10; border-radius: 0; }
body.np-preset-nebula .np-card__body { padding: 15px 16px 17px; }
body.np-preset-nebula .np-card__title { font-size: 16px; font-weight: 700; line-height: 1.5; letter-spacing: -.1px; }
body.np-preset-nebula .np-card__title a { color: var(--sp-ink); }
body.np-preset-nebula .np-card:hover .np-card__title a { color: var(--sp-indigo-dark); }
body.np-preset-nebula .np-card__body > p { color: var(--sp-sub); line-height: 1.7; font-size: 13px; }
body.np-preset-nebula .np-post-meta {
  font-family: var(--sp-mono); font-size: 11px; letter-spacing: .2px;
  color: var(--sp-sub); border-top: 1px dashed var(--sp-line); padding-top: 10px; margin-top: 6px;
}
body.np-preset-nebula .np-post-meta::before { display: none; }
body.np-preset-nebula .np-post-item { border-bottom-color: var(--sp-line); padding-bottom: 18px; gap: 18px; }
body.np-preset-nebula .np-post-item__thumb { border-radius: 10px; }
body.np-preset-nebula .np-post-item__title { font-weight: 700; letter-spacing: -.1px; }
body.np-preset-nebula .np-post-item__title a { color: var(--sp-ink); }
body.np-preset-nebula .np-post-item:hover .np-post-item__title a { color: var(--sp-indigo-dark); }

/* F. 按钮、小工具、页脚 */
body.np-preset-nebula .np-btn--primary {
  border-radius: 999px;
  background: linear-gradient(100deg, var(--sp-indigo-dark), var(--sp-indigo) 60%, #0e7490);
  color: #fff; box-shadow: 0 6px 18px rgba(79, 70, 229, .28); font-weight: 700;
}
body.np-preset-nebula .np-btn--primary:hover { filter: brightness(1.1); }
body.np-preset-nebula .np-widget {
  border: 1px solid var(--sp-line); border-radius: 14px;
  background: var(--sp-surface); box-shadow: var(--sp-glow); padding: 19px;
}
body.np-preset-nebula .np-widget__title {
  font-family: var(--sp-mono); font-size: 13px; font-weight: 700;
  letter-spacing: .8px; text-transform: uppercase; border-bottom-color: var(--sp-line);
}
body.np-preset-nebula .np-widget__title::before {
  width: 8px; height: 8px; border-radius: 2px;
  background: linear-gradient(135deg, var(--sp-indigo), var(--sp-cyan));
}
body.np-preset-nebula .np-footer {
  border-top: 1px solid var(--sp-line);
  background: linear-gradient(180deg, var(--sp-soft), var(--sp-surface));
  color: var(--sp-sub);
}
body.np-preset-nebula .np-side-tools[data-np-drag="all"] .np-side-tools__body {
  border-radius: 14px; box-shadow: var(--sp-glow);
}

/* G. 文章页 */
body.np-preset-nebula .np-single {
  border: 1px solid var(--sp-line); border-radius: 16px;
  background: var(--sp-surface); box-shadow: var(--sp-glow); padding: 32px 36px;
}
body.np-preset-nebula .np-single__title { font-weight: 800; letter-spacing: -.5px; line-height: 1.36; }
body.np-preset-nebula .np-single__meta { font-family: var(--sp-mono); font-size: 12px; border-bottom-color: var(--sp-line); }
body.np-preset-nebula .np-single__cats a {
  border-radius: 999px; background: var(--np-primary-soft); color: var(--sp-indigo-dark);
  font-family: var(--sp-mono); font-size: 11.5px;
}
body.np-preset-nebula .np-entry { font-size: 16px; line-height: 1.9; }
body.np-preset-nebula .np-entry h2,
body.np-preset-nebula .np-entry h3 {
  border-left: 0; padding-left: 0; font-weight: 800; letter-spacing: -.2px;
}
body.np-preset-nebula .np-entry h2::before,
body.np-preset-nebula .np-entry h3::before { display: none; }
body.np-preset-nebula .np-entry blockquote {
  border-left: 3px solid var(--sp-indigo); border-radius: 0 10px 10px 0;
  background: var(--sp-soft); color: var(--sp-sub);
}
body.np-preset-nebula .np-pa__act { border-radius: 999px; }
body.np-preset-nebula .np-pa__act.is-active { background: var(--np-primary-soft); color: var(--sp-indigo-dark); }

/* H. 暗色：光晕增强、彩条更亮，文字沿用暗色令牌 */
body.np-dark.np-preset-nebula {
  --sp-glow: 0 0 0 1px rgba(154, 166, 255, .14), 0 8px 26px rgba(0, 0, 0, .38);
  --sp-glow-hi: 0 0 0 1px rgba(154, 166, 255, .42), 0 16px 44px rgba(79, 70, 229, .34);
  background-color: var(--np-bg);
  background-image:
    radial-gradient(980px 460px at 6% -10%, rgba(79, 70, 229, .24), transparent 70%),
    radial-gradient(820px 420px at 96% 0%, rgba(34, 211, 238, .14), transparent 72%),
    radial-gradient(rgba(154, 166, 255, .06) 1px, transparent 1px);
  background-size: auto, auto, 18px 18px;
}
body.np-dark.np-preset-nebula .np-header {
  background: linear-gradient(100deg, #0d1030 0%, #1b1f52 48%, #2b2580 78%, #075267 100%);
}
body.np-dark.np-preset-nebula .np-footer {
  background: linear-gradient(180deg, var(--np-bg-soft), var(--np-bg));
  border-top-color: var(--np-line);
}
body.np-dark.np-preset-nebula .np-card::before { opacity: 1; }
body.np-dark.np-preset-nebula .np-btn--primary { color: #0d1030; background: linear-gradient(100deg, #b9c2ff, #9aa6ff 60%, #67e8f9); }


/* ==========================================================================
   47.5 统一响应式：1100 / 900 / 560 三档降列与手机紧凑化
   --------------------------------------------------------------------------
   列数一律写 --np-cols（47.0.1 用 repeat(var(--np-cols)) 消费），这样主题
   960 / 640 断点里对 .np-post-grid 的直接覆盖不会把方案列数抢回去。
   注意：newspress_style_css() 的动态令牌由 wp_add_inline_style 输出在
   style.css <link> 之后，其 body.np-preset-* .np-post-grid{--np-cols:N}
   特异性 (0,2,1) 会盖掉普通响应式规则。这里统一加 html 前缀提到 (0,2,2)，
   保证三档降列在真实站点里真正生效。timeline 本来就是单列，只调间距与轴上留白。
   ========================================================================== */

@media (max-width: 1100px) {
  html body.np-preset-newsprint .np-post-grid { --np-cols: 2; gap: 0 18px; }
  html body.np-preset-gallery .np-post-grid   { --np-cols: 2; gap: 15px; }
  html body.np-preset-nebula .np-post-grid    { --np-cols: 3; gap: 15px; }
  body.np-preset-newsprint .np-single { padding: 26px 26px; }
  body.np-preset-gallery .np-single,
  body.np-preset-nebula .np-single { padding: 24px 26px; }
}

@media (max-width: 900px) {
  html body.np-preset-newsprint .np-post-grid { --np-cols: 2; gap: 0 14px; }
  html body.np-preset-gallery .np-post-grid   { --np-cols: 2; gap: 12px; }
  html body.np-preset-nebula .np-post-grid    { --np-cols: 2; gap: 14px; }
  body.np-preset-newsprint .np-module__title { font-size: 21px; }
  body.np-preset-timeline .np-post-list,
  body.np-preset-timeline .np-post-grid { padding-left: 22px; }
  body.np-preset-timeline .np-post-item::before { left: -21px; }
  body.np-preset-newsprint .np-header__actions,
  body.np-preset-gallery .np-header__actions,
  body.np-preset-timeline .np-header__actions,
  body.np-preset-nebula .np-header__actions { gap: 7px; }
}

@media (max-width: 560px) {
  html body.np-preset-newsprint .np-post-grid,
  html body.np-preset-gallery .np-post-grid,
  html body.np-preset-nebula .np-post-grid { --np-cols: 1; gap: 14px; }

  /* 报纸：去首字下沉、缩内边距，标题不至于占满一屏 */
  body.np-preset-newsprint .np-entry > p:first-of-type::first-letter { float: none; font-size: inherit; padding: 0; color: inherit; }
  body.np-preset-newsprint .np-single { padding: 18px 16px; }
  body.np-preset-newsprint .np-single__title { font-size: 26px; }
  body.np-preset-newsprint .np-module { margin-bottom: 22px; }
  body.np-preset-newsprint .np-module__title { font-size: 19px; }
  body.np-preset-newsprint .np-card__body { padding: 12px 13px 14px; }
  body.np-preset-newsprint .np-card__title { font-size: 17px; }

  /* 画廊：单列时图不需要 3/4 那么高，浮层收紧 */
  body.np-preset-gallery .np-card__thumb { aspect-ratio: 16 / 10; }
  body.np-preset-gallery .np-card__body { padding: 32px 13px 12px; }
  body.np-preset-gallery .np-card__title { font-size: 15px; }
  body.np-preset-gallery .np-single { padding: 18px 16px; }
  body.np-preset-gallery .np-module__title { font-size: 17px; letter-spacing: 1px; }

  /* 日志：轴上留白再收一点，缩略图变窄避免挤压文字 */
  body.np-preset-timeline .np-post-list,
  body.np-preset-timeline .np-post-grid { padding-left: 18px; }
  body.np-preset-timeline .np-post-list::before,
  body.np-preset-timeline .np-post-grid::before { left: 4px; }
  body.np-preset-timeline .np-post-item::before { left: -19px; width: 9px; height: 9px; }
  body.np-preset-timeline .np-post-item__thumb { width: 96px; }
  body.np-preset-timeline .np-post-item__title { font-size: 16px; }
  body.np-preset-timeline .np-card { grid-template-columns: 92px minmax(0, 1fr); gap: 11px; }
  body.np-preset-timeline .np-card::after { left: -19px; width: 9px; height: 9px; }
  body.np-preset-timeline .np-card__body > p { display: none; }
  body.np-preset-timeline .np-card__title { font-size: 15px; }
  body.np-preset-timeline .np-single__title { font-size: 25px; }

  /* 科技：去点阵、收阴影，避免暗色下模糊一片 */
  body.np-preset-nebula { background-image: none; }
  body.np-dark.np-preset-nebula { background-image: radial-gradient(560px 300px at 6% -10%, rgba(79, 70, 229, .22), transparent 70%); }
  body.np-preset-nebula .np-single { padding: 20px 16px; }
  body.np-preset-nebula .np-module__title { font-size: 15px; }
  body.np-preset-nebula .np-card__body { padding: 13px 14px 15px; }

  /* 四套共用：顶栏按钮与导航横向可滚，主按钮缩一档 */
  body.np-preset-newsprint .np-header__actions,
  body.np-preset-gallery .np-header__actions,
  body.np-preset-timeline .np-header__actions,
  body.np-preset-nebula .np-header__actions { gap: 6px; }
  body.np-preset-newsprint .np-btn--primary,
  body.np-preset-gallery .np-btn--primary,
  body.np-preset-timeline .np-btn--primary,
  body.np-preset-nebula .np-btn--primary { padding: 0 13px; height: 34px; font-size: 13px; }
  body.np-preset-newsprint .np-nav,
  body.np-preset-gallery .np-nav,
  body.np-preset-timeline .np-nav,
  body.np-preset-nebula .np-nav { overflow-x: auto; scrollbar-width: none; }
  body.np-preset-newsprint .np-nav::-webkit-scrollbar,
  body.np-preset-gallery .np-nav::-webkit-scrollbar,
  body.np-preset-timeline .np-nav::-webkit-scrollbar,
  body.np-preset-nebula .np-nav::-webkit-scrollbar { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  body.np-preset-gallery .np-card,
  body.np-preset-gallery .np-card__thumb img,
  body.np-preset-nebula .np-card { transition: none; }
  body.np-preset-gallery .np-card:hover,
  body.np-preset-nebula .np-card:hover { transform: none; }
}


/* ==========================================================================
   48. 1.8.60 真机修复：内联列数解锁 / 深色顶栏汉堡 / 归档频道条
   --------------------------------------------------------------------------
   真机（375px）上发现三类问题，均源自「模板与 CSS 之间的层叠假设」：
   1) inc/modules.php / template-parts/content-archive.php / single.php 把
      --np-cols 写在元素内联 style 上。内联声明优先级高于任何外部规则，
      连 wp_add_inline_style 输出的动态令牌也盖不过，于是 1100/900/560
      三档降列在归档页、相关文章、首页网格上全部失效：手机仍是 3~4 列，
      卡片被挤到约 70px 宽，正文一字一行、右侧留出大片空白。
   2) 第 42/47 章为深色顶栏方案改了品牌标题与搜索按钮的浅色配色，唯独漏了
      .np-menu-toggle。它仍用 color: var(--np-text)（亮色下是深色），三条杠
      用 currentColor 绘制，压在深色顶栏上几乎不可见。
   3) 归档页没有分类入口，与首页「热门频道」不一致。
   本章只追加规则，1~47 章与既有 8 套方案定义逐字节不变。
   ========================================================================== */

/* --------------------------------------------------------------------------
   48.1 模板声明列数还原（data-np-cols）
   1.8.60 起模板改输出 data-np-cols="N"。这里把 N 还原成 --np-cols，并加
   html body 提到 (0,2,2)：桌面上与原先的内联声明等价，盖过
   wp_add_inline_style 动态输出的 body.np-preset-* .np-post-grid{--np-cols:N}，
   保证 1440px 下既有 4 套方案逐像素零变化；48.2 的响应式规则特异性更高
   (0,3,2) 且位于本章之后，只在断点内接管列数。
   -------------------------------------------------------------------------- */
html body .np-post-grid[data-np-cols="1"], html body .np-video-grid[data-np-cols="1"] { --np-cols: 1; }
html body .np-post-grid[data-np-cols="2"], html body .np-video-grid[data-np-cols="2"] { --np-cols: 2; }
html body .np-post-grid[data-np-cols="3"], html body .np-video-grid[data-np-cols="3"] { --np-cols: 3; }
html body .np-post-grid[data-np-cols="4"], html body .np-video-grid[data-np-cols="4"] { --np-cols: 4; }
html body .np-post-grid[data-np-cols="5"], html body .np-video-grid[data-np-cols="5"] { --np-cols: 5; }
html body .np-post-grid[data-np-cols="6"], html body .np-video-grid[data-np-cols="6"] { --np-cols: 6; }

/* --------------------------------------------------------------------------
   48.2 全方案响应式提权（1100 / 900 / 560 / 340）
   真实站点里 newspress_style_css() 的 body.np-preset-* .np-post-grid{--np-cols:N}
   由 wp_add_inline_style 输出在 style.css <link> 之后，第 42 章既有三套方案的
   响应式规则 (0,2,1) 会被它盖掉；第 47 章用 html 前缀修好了新增四套，既有
   三套仍漏。这里用 html body ... [data-np-cols] 提到 (0,3,2)，对 8 套方案
   统一生效，列数值逐档复刻 42/47 章原有设计（星云 1100 仍 3 列、导购 560
   仍 2 列、340 再降 1 列），只提权不改观感。只命中带 data-np-cols 的模板
   网格，不干扰 20 个小工具区域里由 data-np-scope/data-np-cols 控制的网格。
   -------------------------------------------------------------------------- */
@media (max-width: 1100px) {
  html body .np-post-grid[data-np-cols],
  html body .np-video-grid[data-np-cols] { --np-cols: 2; }
}
@media (min-width: 901px) and (max-width: 1100px) {
  /* 只作用于 901~1100 这一段：若写成单纯 max-width:1100，这条 (0,3,2)
     会在 375px 下依然压住 560 档的单列规则，把卡片社区 / 星云科技锁回 3 列。 */
  html body.np-preset-nebula .np-post-grid[data-np-cols],
  html body.np-preset-cards .np-post-grid[data-np-cols],
  html body.np-preset-shop .np-post-grid[data-np-cols] { --np-cols: 3; }
}

@media (max-width: 900px) {
  html body .np-post-grid[data-np-cols],
  html body .np-video-grid[data-np-cols] { --np-cols: 2; }
}

@media (max-width: 560px) {
  html body .np-post-grid[data-np-cols],
  html body .np-video-grid[data-np-cols] { --np-cols: 1; }
  html body.np-preset-shop .np-post-grid[data-np-cols] { --np-cols: 2; }
}

@media (max-width: 340px) {
  html body.np-preset-shop .np-post-grid[data-np-cols] { --np-cols: 1; }
}

/* --------------------------------------------------------------------------
   48.3 深色顶栏方案的汉堡按钮
   基础 .np-menu-toggle 在手机断点里 color: var(--np-text)，三条杠由
   background: currentColor 绘制。卡片社区（紫渐变顶栏）、影像画廊（墨黑）、
   星云科技（深墨蓝渐变）三套亮色方案的 --np-text 都是深色，白框里于是只剩
   极暗的三条线甚至完全空白。这里按各自顶栏的圆角与配色补齐，并覆盖抽屉
   展开态，避免 aria-expanded 切换瞬间闪回深色。
   -------------------------------------------------------------------------- */
body.np-preset-cards .np-menu-toggle,
body.np-preset-gallery .np-menu-toggle,
body.np-preset-nebula .np-menu-toggle {
  color: rgba(255, 255, 255, .94);
  border-color: rgba(255, 255, 255, .48);
  background: rgba(255, 255, 255, .08);
}
body.np-preset-cards .np-menu-toggle:hover,
body.np-preset-gallery .np-menu-toggle:hover,
body.np-preset-nebula .np-menu-toggle:hover,
body.np-preset-cards .np-menu-toggle[aria-expanded='true'],
body.np-preset-gallery .np-menu-toggle[aria-expanded='true'],
body.np-preset-nebula .np-menu-toggle[aria-expanded='true'] {
  color: #fff;
  border-color: rgba(255, 255, 255, .85);
}
body.np-preset-cards .np-menu-toggle { border-radius: 999px; }
body.np-preset-gallery .np-menu-toggle { border-radius: 6px; }
body.np-preset-nebula .np-menu-toggle { border-radius: 8px; }

/* 浅色顶栏方案把汉堡边框与右侧按钮统一，避免出现两种圆角 / 两种描边。 */
body.np-preset-newsprint .np-menu-toggle,
body.np-preset-reading .np-menu-toggle,
body.np-preset-shop .np-menu-toggle,
body.np-preset-timeline .np-menu-toggle {
  border-color: var(--np-line);
  color: var(--np-text);
}
body.np-preset-newsprint .np-menu-toggle { border-radius: 2px; }
body.np-preset-gallery .np-menu-toggle__bars i,
body.np-preset-nebula .np-menu-toggle__bars i,
body.np-preset-cards .np-menu-toggle__bars i { background: currentColor; }

/* --------------------------------------------------------------------------
   48.4 归档页频道条
   archive.php 在归档标题下输出 .np-cats--archive，复用首页「热门频道」的
   胶囊样式：桌面自适应换行、≤640px 单行横滑（第 5 章已有规则），不会撑宽
   页面。当前分类高亮走设计令牌，8 套方案自动跟随亮 / 暗与主题主色。
   -------------------------------------------------------------------------- */
.np-cats--archive { margin: 0 0 22px; }
.np-cats--archive .np-cat.is-active {
  border-color: var(--np-primary);
  background: var(--np-primary-soft, rgba(0, 0, 0, .05));
  color: var(--np-primary-dark, var(--np-primary));
  font-weight: 700;
}
body.np-preset-newsprint .np-cats--archive .np-cat { border-radius: 2px; }
body.np-preset-gallery .np-cats--archive .np-cat,
body.np-preset-timeline .np-cats--archive .np-cat { border-radius: 6px; }
@media (max-width: 640px) {
  .np-cats--archive { margin-bottom: 18px; }
}

/* --------------------------------------------------------------------------
   48.5 相关文章：单列时收紧卡片，避免 16:9 大图占满一屏
   不改动卡片 DOM 与浮层结构，只调间距与字号，画廊的标题浮层依旧生效。
   -------------------------------------------------------------------------- */
@media (max-width: 560px) {
  .np-related .np-post-grid[data-np-cols] { gap: 12px; }
  .np-related .np-card__title { font-size: 15px; }
}


/* --------------------------------------------------------------------------
   48.6 影像画廊深色页脚适配（1.8.61）
   gallery 亮色模式页脚底是 --sp-night（近黑），但页脚内部子元素仍沿用浅色
   主题的 --np-text / --np-text-2 / --np-muted 深灰文字，在黑底上几乎看不见
   （统计数字、社交按钮、分类链接、副标题、底栏文字都沦陷）；且 .np-footer a
   （特异性 0,1,1）盖不过 .np-footer__list a（0,2,1）等具体子选择器。这里逐
   元素把文字 / 描边切到白系，暗色模式（#0e1015）也一并覆盖。其它方案亮色
   页脚均为浅底，不受影响。
   -------------------------------------------------------------------------- */
body.np-preset-gallery .np-footer__logo { color: #fff; }
body.np-preset-gallery .np-footer__logo:hover { color: var(--sp-amber); }
body.np-preset-gallery .np-footer__desc { color: rgba(255, 255, 255, .62); }
body.np-preset-gallery .np-footer__stats li { color: rgba(255, 255, 255, .55); }
body.np-preset-gallery .np-footer__stats strong { color: #fff; }
body.np-preset-gallery .np-footer__social a,
body.np-preset-gallery .np-footer__social button {
  color: rgba(255, 255, 255, .85);
  border-color: rgba(255, 255, 255, .22);
  background: rgba(255, 255, 255, .06);
}
body.np-preset-gallery .np-footer__social a:hover,
body.np-preset-gallery .np-footer__social button:hover {
  color: #fff; border-color: var(--sp-amber); background: rgba(245, 180, 76, .18);
}
body.np-preset-gallery .np-footer__title { color: #fff; }
body.np-preset-gallery .np-footer__list a { color: rgba(255, 255, 255, .78); }
body.np-preset-gallery .np-footer__list a:hover { color: var(--sp-amber); }
body.np-preset-gallery .np-footer__list-text { color: rgba(255, 255, 255, .78); }
body.np-preset-gallery .np-footer__count {
  color: rgba(255, 255, 255, .6);
  border-color: rgba(255, 255, 255, .18);
  background: rgba(255, 255, 255, .05);
}
body.np-preset-gallery .np-footer__empty { color: rgba(255, 255, 255, .55); }
body.np-preset-gallery .np-footer__widgets .np-widget__title { color: #fff; }
body.np-preset-gallery .np-footer__widgets .np-widget li { color: rgba(255, 255, 255, .78); }
body.np-preset-gallery .np-footer__bottom { color: rgba(255, 255, 255, .55); }
body.np-preset-gallery .np-footer__copy { color: rgba(255, 255, 255, .55); }
body.np-preset-gallery .np-footer__nav a { color: rgba(255, 255, 255, .6); }
body.np-preset-gallery .np-footer__nav a:hover { color: var(--sp-amber); }
body.np-preset-gallery .np-footer__icp,
body.np-preset-gallery .np-footer__icp a { color: rgba(255, 255, 255, .55); }
body.np-preset-gallery .np-footer__icp a:hover { color: var(--sp-amber); }

/* =========================================================================
 * 第 49 章 · 小工具按方案换肤（页脚小工具 + 杂志默认方案 + 侧栏列表点缀）
 * -------------------------------------------------------------------------
 * 背景：第 42–47 章已经给 7 套方案的「侧栏小工具容器 + 标题」做了换肤，但
 * 「页脚小工具」一直是通用的「无边框 + 全大写小标题」，8 套方案长得一模一样，
 * 和各自页脚的脾气完全不搭；杂志作为默认方案则完全没有小工具换肤块，是唯一的
 * 「裸」方案。标签云 .np-tag、列表链接 a 已通过 --np-* 令牌自动跟随明暗与主色，
 * 无需重复处理。
 * 做法：纯加法，不改动既有第 42–47 章块。给每套方案的页脚小工具标题加上「方案主色
 * 短条 + 方案字体」（衬线方案取消全大写，与各自侧栏标题语气一致），页脚列表悬停
 * 走方案主色；补上杂志方案的小工具块；并为 4 套强品牌方案（卡片 / 导购 / 画廊 /
 * 星云）的侧栏列表悬停换成方案色，让小工具区整体跟着方案走。文字色一律沿用
 * --np-text（明暗自动适配），避免在深色页脚下对比度翻车。
 * ========================================================================= */

/* --- A. 页脚小工具标题：方案主色短条 + 方案字体（文字色保持 --np-text 自动适配）--- */

/* 卡片社区 cards：圆角渐变方点 + 无大写，与侧栏标题一致 */
body.np-preset-cards .np-footer__widgets .np-widget__title {
  font-weight: 800; letter-spacing: -.2px; text-transform: none;
}
body.np-preset-cards .np-footer__widgets .np-widget__title::before {
  display: block; width: 8px; height: 8px; border-radius: 3px;
  background: linear-gradient(135deg, var(--sp-brand), var(--sp-brand2));
}
body.np-preset-cards .np-footer__widgets .np-widget li a:hover { color: var(--sp-brand); }

/* 极简阅读 reading：衬线 + 细横线短条，素雅 */
body.np-preset-reading .np-footer__widgets .np-widget__title {
  font-family: var(--sp-serif); font-size: 14px; font-weight: 600;
  letter-spacing: .4px; text-transform: none;
}
body.np-preset-reading .np-footer__widgets .np-widget__title::before {
  display: block; width: 14px; height: 2px; border-radius: 2px; background: var(--sp-ink);
}
body.np-preset-reading .np-footer__widgets .np-widget li a:hover { color: var(--sp-ink); }

/* 导购商城 shop：竖向渐变条 + 无大写，与侧栏标题一致 */
body.np-preset-shop .np-footer__widgets .np-widget__title {
  font-weight: 800; text-transform: none;
}
body.np-preset-shop .np-footer__widgets .np-widget__title::before {
  display: block; width: 5px; height: 16px; border-radius: 3px;
  background: linear-gradient(180deg, var(--sp-brand), var(--sp-brand2));
}
body.np-preset-shop .np-footer__widgets .np-widget li a:hover { color: var(--sp-brand); }

/* 报刊头条 newsprint：衬线 + 报刊红竖条，与侧栏标题一致 */
body.np-preset-newsprint .np-footer__widgets .np-widget__title {
  font-family: var(--sp-serif); font-size: 15px; font-weight: 800; text-transform: none;
}
body.np-preset-newsprint .np-footer__widgets .np-widget__title::before {
  display: block; width: 4px; height: 16px; border-radius: 0; background: var(--sp-red);
}
body.np-preset-newsprint .np-footer__widgets .np-widget li a:hover { color: var(--sp-red); }

/* 影像画廊 gallery：保留全大写（与侧栏标题一致），琥珀短条；文字色沿用既有 #fff */
body.np-preset-gallery .np-footer__widgets .np-widget__title {
  font-weight: 800; letter-spacing: 1.1px;
}
body.np-preset-gallery .np-footer__widgets .np-widget__title::before {
  display: block; width: 4px; height: 15px; border-radius: 2px; background: var(--sp-amber);
}
body.np-preset-gallery .np-footer__widgets .np-widget li a:hover { color: var(--sp-amber); }

/* 时光日志 timeline：等宽 + 蓝色圆点，与侧栏标题一致 */
body.np-preset-timeline .np-footer__widgets .np-widget__title {
  font-family: var(--sp-mono); font-weight: 700; letter-spacing: .4px; text-transform: none;
}
body.np-preset-timeline .np-footer__widgets .np-widget__title::before {
  display: block; width: 8px; height: 8px; border-radius: 50%; background: var(--sp-blue);
}
body.np-preset-timeline .np-footer__widgets .np-widget li a:hover { color: var(--sp-blue); }

/* 星云科技 nebula：等宽 + 青紫渐变方点，保留全大写（与侧栏标题一致） */
body.np-preset-nebula .np-footer__widgets .np-widget__title {
  font-family: var(--sp-mono); font-weight: 700; letter-spacing: .8px;
}
body.np-preset-nebula .np-footer__widgets .np-widget__title::before {
  display: block; width: 8px; height: 8px; border-radius: 2px;
  background: linear-gradient(135deg, var(--sp-indigo), var(--sp-cyan));
}
body.np-preset-nebula .np-footer__widgets .np-widget li a:hover { color: var(--sp-cyan); }

/* 杂志 magazine（默认）：主色细条，干净无大写 */
body.np-preset-magazine .np-footer__widgets .np-widget__title {
  font-weight: 700; letter-spacing: .2px; text-transform: none;
}
body.np-preset-magazine .np-footer__widgets .np-widget__title::before {
  display: block; width: 3px; height: 15px; border-radius: 2px; background: var(--np-primary);
}
body.np-preset-magazine .np-footer__widgets .np-widget li a:hover { color: var(--np-primary); }

/* --- B. 杂志（默认）方案小工具块：之前完全缺失，补一份与其它方案同族的盒装换肤 --- */
body.np-preset-magazine .np-widget {
  border: 1px solid var(--np-line); border-radius: var(--np-radius);
  background: var(--np-bg); box-shadow: var(--np-shadow); padding: 18px;
}
body.np-preset-magazine .np-widget__title {
  font-weight: 700; letter-spacing: .2px;
}
body.np-preset-magazine .np-widget__title::before {
  width: 3px; height: 15px; border-radius: 2px; background: var(--np-primary);
}

/* --- C. 侧栏列表悬停走方案主色（强品牌方案，避免蓝色和品牌调性打架）--- */
body.np-preset-cards .np-widget li a:hover { color: var(--sp-brand); }
body.np-preset-shop .np-widget li a:hover { color: var(--sp-brand); }
body.np-preset-gallery .np-widget li a:hover { color: var(--sp-amber); }
body.np-preset-nebula .np-widget li a:hover { color: var(--sp-cyan); }

/* ==========================================================================
   第 50 章 · 全宽区域：流式子工具宽度自适应（1.8.64）
   --------------------------------------------------------------------------
   首页「顶部 / 底部全宽度」区域用 auto-fit 网格把小工具自动分栏，方便「全宽模块
   占整行、窄卡片自动分栏」。但「通用(both)」类流式子工具——快讯滚动、站内搜索、
   标题与按钮、间距与分隔、公告、广告、图标卡、自定义 HTML 等——本就自带视觉盒子，
   被外层 .np-widget 卡片壳再包一层后会出现三类问题：

     (1) 间距与分隔只输出一个空的 .np-wx-spacer，没有标题也没有内容，外层卡片壳
         把它变成一张空卡，网格里看着像「破洞」；
     (2) 快讯 / 搜索等自身已有边框与内边距，再套一层卡片 = 双重描边；搜索挂件更糟，
         内部 newspress_sidebar_part_search 又嵌了一层 .np-widget + 标题，出现双卡片
         与双「站内搜索」标题、留白翻倍；
     (3) 这些流式子工具被强行等列化，与其「宽度自适应、放哪都行」的定位不符。

   这里只在「全宽区域」内做减法：剥离 both 类挂件的外层卡壳，让它们按列宽自适应；
   间距挂件改为整行透明留白（不再占一格变破洞）；同排卡片等高对齐。
   侧栏 / 内容列区域的卡片样式完全不动，side 类（热门 / 最新 / 标签等）列表挂件
   也不受影响——它们的 data-np-scope 不是 both，不会命中下面规则。

   选择器命中依据：widget-scope.php 在前台把 scope 写进外层 .np-wa__widget 的
   data-np-scope 属性；间距挂件的 classname 为 np-widget-spacer（由 id_base 派生）。
   body 类：无新增。
   ========================================================================== */

/* 50.1 全宽区域里「通用(both)」流式子工具：剥离外层 .np-widget 卡片壳。
   它们的内部（np-wx-* 盒子 / 搜索框 / 广告位）自带边框与内边距，外层卡壳纯属重复。 */
.np-wa--top > .np-wa__widget[data-np-scope="both"],
.np-wa--bottom > .np-wa__widget[data-np-scope="both"] {
  border: 0;
  background: transparent;
  box-shadow: none;
  padding: 0;
  overflow: visible;
}

/* 50.2 间距与分隔：在全宽区域里改为整行透明留白 / 分隔线，不再占一格变成空卡破洞。
   手机端（≤720px）网格已退化为单列，这里同样让它占满整行。 */
.np-wa--top > .np-wa__widget.np-widget-spacer,
.np-wa--bottom > .np-wa__widget.np-widget-spacer,
.np-wa--top > .np-wa__widget:has(> .np-wx-spacer),
.np-wa--bottom > .np-wa__widget:has(> .np-wx-spacer) {
  grid-column: 1 / -1;
  border: 0;
  background: transparent;
  box-shadow: none;
  padding: 0;
  overflow: visible;
  min-height: 0;
}

/* 50.3 全宽区域同排卡片等高：避免快讯 / 搜索 / 标题与按钮高度参差。
   50.4 间距挂件在侧栏（窄卡）里保持普通留白即可，不进入上面的整行规则。 */

/* ==========================================================================
   第 51 章 · 全宽区域：通用 / 宽度自适应挂件独占整行（1.8.65）
   --------------------------------------------------------------------------
   问题：.np-wa--top / .np-wa--bottom 用
         grid-template-columns: repeat(auto-fit, minmax(260px, 1fr))
         自动分栏，电脑版 1100px 宽能塞下 4 列。第 41 章 41.1 只给
         data-np-scope="wide" 的首页模块加了 grid-column:1/-1 独占整行，
         而「通用(both) / 宽度自适应」类挂件——快讯滚动、站内搜索、标题与按钮、
         间距与分隔、公告、广告、图标卡、按钮组、自定义 HTML、数据统计——
         不命中 wide，于是被压成 4 个约 260px 的窄列：快讯文字被截断、
         搜索按钮被挤成竖排、标题与按钮挤在窄卡里，整体「像侧栏组件」，
         与「首页-顶部全宽度 / 全宽模块」的定位完全不符。

   1.8.64（第 50 章）已剥离外层重复卡片壳、处理间距空卡与搜索双标题，
   但没有改列布局；这里补上关键一步：全宽区域内的 both 挂件一律独占整行、
   纵向堆叠铺满全宽，与其「宽度自适应、放哪都行」的定位一致。

   精确边界：
   - 只在 .np-wa--top / .np-wa--bottom（顶部 / 底部全宽度）内生效；
   - 只命中 data-np-scope="both"；side 类窄卡（热门 / 最新 / 标签 / 会员等）
     仍走 auto-fit 自动分栏，wide 类本来已独占整行，二者均不受影响；
   - 侧栏、主内容上 / 下等其它区域完全不动；
   - 手机端网格本就是单列（第 41 章 41.4），行为不变。
   ========================================================================== */

/* 51.1 电脑 / 平板：通用挂件横贯整行、从上往下堆叠，不再挤成侧栏式窄列。
   min-width:0 同时修掉手机端基线遗留：单列 1fr(=minmax(auto,1fr)) 会被
   nowrap 长快讯文字按 min-width:auto 撑到 500+px 造成横向溢出；桌面端列定义
   是 minmax(260px,1fr)，不受此声明影响。 */
.np-wa--top > .np-wa__widget[data-np-scope="both"],
.np-wa--bottom > .np-wa__widget[data-np-scope="both"] {
  grid-column: 1 / -1;
  min-width: 0;
}

/* ==========================================================================
   第 52 章 · 首页轮播自定义宽度 / 高度（1.8.66）
   --------------------------------------------------------------------------
   「NP · 首页轮播」小工具新增「宽度 (px)」「高度 (px)」两项，语义是「上限」：
   前台只把数值渲染成 .np-slider 上的 CSS 变量与 data-np-size 标记，绝不内联
   width/height（沿用 1.8.60「内联 --np-cols 锁死列数」的教训）。这里统一消费：

     width         : min(var(--np-slider-w, 100%), 100%)  → 永不宽于所在容器；
     aspect-ratio  : var(--np-slider-ar, 16/9)            → 高度随实际宽度等比缩放；
     max-height    : var(--np-slider-maxh, none)          → 用户填的高度只作上限。

   于是同一份配置放到「顶部全宽度 / 主内容列 / 侧栏 / 手机」都会自动收敛：
   宽处按上限铺开，窄处等比缩小，既不撑破容器、也不会塌成竖条，图片始终
   object-fit:cover 不变形。窄于容器时居中对齐更协调。

   历史默认高度（桌面 340 / 小屏 240 / 侧栏 200 / 手机 16:9）只在没有
   data-np-size 标记时生效；用户一旦设置自定义尺寸，用 !important 压过这些
   「按位置硬编码」的降级规则——这是用户显式意图，且本规则本身已自带响应式
   收敛，媒体查询无需再覆盖它。两个字段都不填时 PHP 不输出 data-np-size，
   外观与 1.8.65 完全一致（零回归）。
   ========================================================================== */

/* 52.1 只对「已设置自定义尺寸」的轮播生效；width 用 min 封顶到 100%，
   保证全宽、内容列、侧栏、手机任何位置都不撑破容器。 */
.np-slider[data-np-size] {
  width: min(var(--np-slider-w, 100%), 100%);
  max-width: 100%;
  margin-left: auto;
  margin-right: auto;
  height: auto !important;
  min-height: 0;
  aspect-ratio: var(--np-slider-ar, 16 / 9) !important;
  max-height: var(--np-slider-maxh, none) !important;
  overflow: hidden;
}

/* 52.2 让轨道 / 单帧填满容器高度：内部图片是 absolute + cover，
   高度由 .np-slider 的 aspect-ratio 决定，比例变化也不会拉伸变形。 */
.np-slider[data-np-size] .np-slider__track { height: 100%; }
.np-slider[data-np-size] .np-slider__slide { min-height: 0; height: 100%; }

/* 52.3 自定义尺寸下取消按位置的固定高度降级（历史规则用 !important 覆盖，
   这里同样提权，确保侧栏 / 手机不会被塞回 200px 或 16:9）。 */
.np-wa[data-np-wide="0"] .np-wa__widget[data-np-scope="wide"] .np-slider[data-np-size],
.np-sidebar-col .np-wa__widget[data-np-scope="wide"] .np-slider[data-np-size] {
  height: auto !important;
  min-height: 0;
}
.np-wa__widget[data-np-scope] .np-slider[data-np-size] {
  aspect-ratio: var(--np-slider-ar, 16 / 9) !important;
  height: auto !important;
}
.np-wa__widget[data-np-scope] .np-slider[data-np-size] .np-slider__slide {
  min-height: 0;
}

/* 52.4 极窄位置（侧栏 / 手机）的字幕精简：等比缩小后容器可能只有百来像素高，
   大号标题 + 摘要 + 标签会把 caption 顶出可视区（标题被 overflow 裁掉）。
   用容器查询按「轮播自身宽度」而非视口判断——侧栏在宽屏下同样是窄容器。
   inline-size 容器只约束行向尺寸，不影响 aspect-ratio 推算的高度。 */
.np-slider[data-np-size] { container-type: inline-size; }
@container (max-width: 440px) {
  .np-slider[data-np-size] .np-slider__caption { padding: 12px 14px; max-width: 100%; }
  .np-slider[data-np-size] .np-slider__caption h2 { font-size: 16px; margin-bottom: 4px; }
  .np-slider[data-np-size] .np-slider__caption p,
  .np-slider[data-np-size] .np-slider__tag { display: none; }
}
@container (max-width: 300px) {
  .np-slider[data-np-size] .np-slider__caption h2 { font-size: 14px; }
}

/* ==========================================================================
   第 53 章 · 论坛社区方案（1.8.67，参考 52pojie / Discuz 版式）
   --------------------------------------------------------------------------
   仅作用于 body.np-preset-forum，其它 8 套方案逐字节不受影响。
   设计取自 52pojie 经典配色：顶部菜单蓝 #2B7ACD、分区表头浅蓝 #E8EFF5、
   置顶红 #dc3545、暗色 #212529。刻意「不把顶栏染深蓝」——1.8.60 深色顶栏
   曾导致三条杠 / 图标按钮不可见，论坛版改用「蓝色顶边 + 分区表头蓝条 +
   紧凑主题行」表达论坛气质，头部所有按钮保持既有令牌与可见性。
   全部颜色走 --np-*；明暗切换时 body.np-dark.np-preset-forum 再覆盖一次。
   ========================================================================== */

/* 53.1 蓝色顶边与品牌主色：一条 3px 主色线点题，不动顶栏文字体系。 */
body.np-preset-forum .np-header { border-top: 3px solid var(--np-primary); }
body.np-preset-forum .np-brand__name em { color: var(--np-primary); }
body.np-preset-forum .np-nav a:hover,
body.np-preset-forum .np-nav .current-menu-item > a,
body.np-preset-forum .np-nav .current-menu-ancestor > a {
  color: #fff;
  background: var(--np-primary);
}

/* 53.2 分区表头：小工具 / 区块标题改成 Discuz 版块表头——浅蓝底、左色条、
   下边框加粗、字号略收、字距略宽，信息密度更高。 */
body.np-preset-forum .np-widget { border-radius: var(--np-radius); }
body.np-preset-forum .np-widget__title {
  margin: -18px -18px 14px;
  padding: 9px 14px;
  border-bottom: 1px solid var(--np-line);
  background: var(--np-bg-soft);
  font-size: 14px;
  letter-spacing: .3px;
}
body.np-preset-forum .np-widget__title::before { width: 4px; height: 14px; border-radius: 1px; }

/* 53.3 版块导航：分类 chip 从胶囊改成方块（Discuz 版块链接方块感）。 */
body.np-preset-forum .np-cat {
  border-radius: var(--np-radius-sm);
  padding: 7px 12px;
  font-size: 13px;
}
body.np-preset-forum .np-cat:hover { transform: none; border-color: var(--np-primary); background: var(--np-primary-soft); }
body.np-preset-forum .np-cat__dot { border-radius: 2px; }

/* 53.4 主题行：列表条目从「缩略图 + 摘要」重排成紧凑论坛帖行——
   左侧帖子图标、标题加粗单行、作者/时间/回复数与右侧高亮计数，
   行距收紧、斑马纹、悬停浅蓝、细线分隔，模拟 Discuz 主题列表。
   结构沿用 .np-post-list > .np-post-item，不改任何 PHP 模板。 */
body.np-preset-forum .np-post-list { gap: 0; border: 1px solid var(--np-line); border-radius: var(--np-radius); overflow: hidden; }
body.np-preset-forum .np-post-item {
  position: relative;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 11px 14px;
  margin: 0;
  border-bottom: 1px solid var(--np-line);
  background: var(--np-bg);
}
body.np-preset-forum .np-post-item:last-child { border-bottom: 0; padding-bottom: 11px; }
body.np-preset-forum .np-post-item:nth-child(even) { background: var(--np-bg-soft); }
body.np-preset-forum .np-post-item:hover { background: var(--np-primary-soft); }

/* 帖子类型图标：用首列一个方形徽标代替大缩略图（论坛主题图标）。 */
body.np-preset-forum .np-post-item__thumb {
  grid-column: 1;
  grid-row: 1;
  aspect-ratio: auto;
  width: 34px;
  height: 34px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg);
  overflow: visible;
}
body.np-preset-forum .np-post-item__thumb img { display: none; }
body.np-preset-forum .np-post-item__thumb::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: var(--np-primary-soft);
}
body.np-preset-forum .np-post-item__thumb::before {
  content: '帖';
  position: absolute;
  inset: 0;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 700;
  color: var(--np-primary);
}
body.np-preset-forum .np-post-item__thumb--empty { display: block; min-height: 0; }

/* 置顶 / 精华标：从图片角标改成行内标签，红底白字。 */
body.np-preset-forum .np-post-item__badge {
  position: static;
  display: inline-block;
  margin-right: 6px;
  padding: 1px 6px;
  border-radius: 2px;
  background: var(--np-accent);
  color: #fff;
  font-size: 11px;
  vertical-align: middle;
}

/* 标题 / 摘要 / 元信息：压成论坛帖行的紧凑排版。 */
body.np-preset-forum .np-post-item__body { grid-column: 2; grid-row: 1; min-width: 0; }
body.np-preset-forum .np-post-item__title { margin: 0 0 3px; font-size: 14.5px; line-height: 1.4; }
body.np-preset-forum .np-post-item__title a { display: inline; -webkit-line-clamp: unset; overflow: visible; }
body.np-preset-forum .np-post-item__title a:hover { color: var(--np-primary); }
body.np-preset-forum .np-post-item__excerpt {
  margin: 0;
  font-size: 12.5px;
  color: var(--np-muted);
  -webkit-line-clamp: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: block;
}
body.np-preset-forum .np-post-item .np-post-meta { grid-column: 3; grid-row: 1; gap: 10px; font-size: 12px; }

/* 53.5 明色下分区表头氛围层：正文区浅灰蓝、卡片白，论坛信息分区更清晰。 */
body.np-preset-forum .np-content,
body.np-preset-forum .np-main { background: transparent; }

/* 53.6 暗色：分区表头转深板岩蓝、主题行 hover 用深蓝，主色提亮，文字保持高对比。 */
body.np-dark.np-preset-forum { --np-primary-dark: #4a86d8; }
body.np-dark.np-preset-forum .np-widget__title { background: color-mix(in srgb, var(--np-primary) 12%, var(--np-bg-soft)); }
body.np-dark.np-preset-forum .np-post-item:nth-child(even) { background: color-mix(in srgb, var(--np-bg-soft) 60%, var(--np-bg)); }
body.np-dark.np-preset-forum .np-post-item:hover { background: color-mix(in srgb, var(--np-primary) 18%, var(--np-bg)); }
body.np-dark.np-preset-forum .np-nav a:hover,
body.np-dark.np-preset-forum .np-nav .current-menu-item > a { background: var(--np-primary); color: #fff; }

/* 53.7 手机端：主题行隐藏次要计数列、图标缩小，保证标题完整不裁切。 */
@media (max-width: 640px) {
  body.np-preset-forum .np-post-item { grid-template-columns: 28px minmax(0, 1fr); gap: 10px; padding: 10px 12px; }
  body.np-preset-forum .np-post-item__thumb { width: 28px; height: 28px; }
  body.np-preset-forum .np-post-item .np-post-meta {
    grid-column: 2;
    grid-row: 2;
    gap: 8px;
    font-size: 11px;
  }
  body.np-preset-forum .np-post-item__body { grid-column: 2; grid-row: 1; }
  body.np-preset-forum .np-widget__title { margin: -14px -14px 12px; padding: 8px 12px; }
}

/* ==========================================================================
   第 54 章 · 下载中心（1.8.67）
   --------------------------------------------------------------------------
   通用文件下载：APK / PDF / EXE / ZIP / DOC / 图片 / 音视频 / 文本，
   本地文件 + 外链多线路。全新 .np-dl-* 命名空间，与既有 .np-soft-*
   （软件下载）完全隔离，其它页面逐字节不受影响。
   全部颜色走 --np-* 令牌 → 自动适配 9 套页面样式方案与明暗模式。
   文件类型角标用 data-np-dl-type 属性选择器上色（54.2），不写内联样式。
   ========================================================================== */

/* 54.1 面包屑 / 空态 / 区块标题 */
.np-dl-crumb { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 18px 0; font-size: 13px; color: var(--np-muted); }
.np-dl-crumb a { color: var(--np-muted); text-decoration: none; }
.np-dl-crumb a:hover { color: var(--np-primary); }
.np-dl-crumb > span:last-child { color: var(--np-text); }
.np-dl-empty { padding: 46px 20px; text-align: center; color: var(--np-muted); background: var(--np-bg-soft); border: 1px dashed var(--np-line); border-radius: var(--np-radius); }

.np-dl-sec { margin: 26px 0; }
.np-dl-sec__head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin: 0 0 16px; padding-bottom: 10px; border-bottom: 1px solid var(--np-line); }
.np-dl-sec__head h2 { margin: 0; font-size: 20px; }
.np-dl-sec__head a { color: var(--np-primary); font-size: 13px; text-decoration: none; }

/* 54.2 文件类型色板：data-np-dl-type 命中即上色，明暗共用。 */
.np-dl-card,
.np-dl-type,
.np-dl-rank__tag,
.np-dl-single,
.np-dl-related__tag,
.np-dl-cats__tag { --np-dl-c: #2271b1; }
[data-np-dl-type="apk"]   { --np-dl-c: #17a866; }
[data-np-dl-type="exe"]   { --np-dl-c: #0a6ec6; }
[data-np-dl-type="dmg"]   { --np-dl-c: #5b6b7a; }
[data-np-dl-type="pdf"]   { --np-dl-c: #d63b40; }
[data-np-dl-type="zip"]   { --np-dl-c: #cf8512; }
[data-np-dl-type="doc"]   { --np-dl-c: #2b579a; }
[data-np-dl-type="xls"]   { --np-dl-c: #1c7a48; }
[data-np-dl-type="ppt"]   { --np-dl-c: #c23d1e; }
[data-np-dl-type="img"]   { --np-dl-c: #7b4fc9; }
[data-np-dl-type="media"] { --np-dl-c: #b23a80; }
[data-np-dl-type="iso"]   { --np-dl-c: #3f6192; }
[data-np-dl-type="txt"]   { --np-dl-c: #5c6774; }
[data-np-dl-type="all"]   { --np-dl-c: var(--np-primary); }

/* 54.3 门户页 hero + 统计 + 搜索 */
.np-dl-hero { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 22px; padding: 26px 28px; margin: 6px 0 22px; border: 1px solid var(--np-line); border-radius: var(--np-radius); background: var(--np-bg); }
.np-dl-hero__main { flex: 1 1 380px; min-width: 0; }
.np-dl-hero__main h1 { margin: 0 0 8px; font-size: 27px; }
.np-dl-hero__main p { margin: 0 0 16px; color: var(--np-text-2); font-size: 14px; line-height: 1.8; }
.np-dl-search { display: flex; max-width: 460px; }
.np-dl-search input[type=search] { flex: 1 1 auto; min-width: 0; padding: 10px 14px; border: 1px solid var(--np-line); border-right: 0; border-radius: var(--np-radius-sm) 0 0 var(--np-radius-sm); background: var(--np-bg-soft); color: var(--np-text); font-size: 14px; }
.np-dl-search input[type=search]:focus { outline: none; border-color: var(--np-primary); }
.np-dl-search button { flex: 0 0 auto; padding: 10px 20px; border: 0; border-radius: 0 var(--np-radius-sm) var(--np-radius-sm) 0; background: var(--np-primary); color: #fff; font-size: 14px; cursor: pointer; }
.np-dl-search button:hover { background: var(--np-primary-dark); }
.np-dl-hero__stats { display: flex; gap: 26px; flex: 0 0 auto; }
.np-dl-hero__stats > div { display: flex; flex-direction: column; align-items: center; gap: 2px; }
.np-dl-hero__stats b { font-size: 24px; color: var(--np-primary); line-height: 1.2; }
.np-dl-hero__stats span { font-size: 12px; color: var(--np-muted); }

/* 54.4 文件类型快捷入口 / 分类 chips / 排序 */
.np-dl-types { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 10px; margin: 0 0 16px; }
.np-dl-type { display: flex; align-items: center; gap: 10px; padding: 12px; border: 1px solid var(--np-line); border-radius: var(--np-radius); background: var(--np-bg); text-decoration: none; transition: var(--np-transition); }
.np-dl-type:hover { border-color: var(--np-dl-c); transform: translateY(-2px); }
.np-dl-type.is-active { border-color: var(--np-dl-c); background: color-mix(in srgb, var(--np-dl-c) 10%, var(--np-bg)); }
.np-dl-type__badge { flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center; min-width: 42px; height: 30px; padding: 0 6px; border-radius: var(--np-radius-sm); background: color-mix(in srgb, var(--np-dl-c) 16%, transparent); color: var(--np-dl-c); font-size: 11px; font-weight: 800; letter-spacing: .3px; }
.np-dl-type__label { color: var(--np-text-2); font-size: 13px; }
.np-dl-type:hover .np-dl-type__label, .np-dl-type.is-active .np-dl-type__label { color: var(--np-text); font-weight: 600; }

.np-dl-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0; }
.np-dl-chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 14px; border: 1px solid var(--np-line); border-radius: 999px; background: var(--np-bg); color: var(--np-text-2); font-size: 13px; text-decoration: none; transition: var(--np-transition); }
.np-dl-chip:hover { border-color: var(--np-primary); color: var(--np-primary); }
.np-dl-chip.is-active { border-color: var(--np-primary); background: var(--np-primary-soft); color: var(--np-primary); font-weight: 600; }
.np-dl-chip i { font-style: normal; font-size: 11px; color: var(--np-muted); }

.np-dl-sort { display: flex; gap: 18px; margin: 8px 0 20px; border-bottom: 1px solid var(--np-line); }
.np-dl-sort__item { padding: 8px 2px 12px; color: var(--np-muted); font-size: 13.5px; text-decoration: none; border-bottom: 2px solid transparent; }
.np-dl-sort__item:hover { color: var(--np-primary); }
.np-dl-sort__item.is-active { color: var(--np-primary); border-bottom-color: var(--np-primary); font-weight: 600; }

/* 54.5 归档标题 */
.np-dl-archive { padding: 22px 0 10px; }
.np-dl-archive__title { margin: 0 0 6px; font-size: 26px; }
.np-dl-archive__count { margin: 0; color: var(--np-muted); font-size: 13px; }
.np-dl-archive__desc { margin-top: 12px; color: var(--np-text-2); font-size: 14px; line-height: 1.8; }

/* 54.6 资源卡片网格 */
.np-dl-grid { display: grid; gap: 16px; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.np-dl-grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.np-dl-grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.np-dl-card { display: flex; flex-direction: column; overflow: hidden; border: 1px solid var(--np-line); border-radius: var(--np-radius); background: var(--np-bg); transition: transform .18s ease, box-shadow .18s ease; }
.np-dl-card:hover { transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0, 0, 0, .07); }
.np-dl-card__media { position: relative; display: flex; align-items: center; justify-content: center; height: 138px; padding: 16px; background: color-mix(in srgb, var(--np-dl-c) 8%, var(--np-bg-soft)); }
.np-dl-card__tag { position: absolute; top: 10px; right: 10px; padding: 3px 9px; border-radius: var(--np-radius-sm); background: var(--np-dl-c); color: #fff; font-size: 11px; font-weight: 800; letter-spacing: .4px; }
.np-dl-card__icon { max-width: 84px; max-height: 84px; border-radius: 16px; object-fit: contain; }
/* 通用「文件」图标：一张折角纸 + 类型色，不依赖任何外部图片。 */
.np-dl-card__file { position: relative; display: inline-block; width: 62px; height: 76px; border: 2px solid var(--np-dl-c); border-radius: 6px; background: color-mix(in srgb, var(--np-dl-c) 12%, var(--np-bg)); }
.np-dl-card__file::before { content: ''; position: absolute; top: -2px; right: -2px; width: 20px; height: 20px; border-left: 2px solid var(--np-dl-c); border-bottom: 2px solid var(--np-dl-c); border-radius: 0 0 0 4px; background: var(--np-bg-soft); }
.np-dl-card__file i { position: absolute; left: 12px; right: 12px; top: 34px; height: 3px; border-radius: 2px; background: var(--np-dl-c); box-shadow: 0 9px 0 var(--np-dl-c), 0 18px 0 color-mix(in srgb, var(--np-dl-c) 45%, transparent); }
.np-dl-card__body { display: flex; flex: 1; flex-direction: column; padding: 14px 16px 16px; min-width: 0; }
.np-dl-card__kind { color: var(--np-dl-c); font-size: 11.5px; font-weight: 600; }
.np-dl-card__title { margin: 5px 0 7px; font-size: 15px; line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.np-dl-card__title a { color: var(--np-text); text-decoration: none; }
.np-dl-card__title a:hover { color: var(--np-primary); }
.np-dl-card__meta { margin: 0 0 8px; color: var(--np-muted); font-size: 12px; }
.np-dl-card__desc { margin: 0 0 12px; color: var(--np-text-2); font-size: 12.5px; line-height: 1.7; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.np-dl-card__foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: auto; padding-top: 10px; border-top: 1px dashed var(--np-line); }
.np-dl-card__count { color: var(--np-muted); font-size: 12px; }
.np-dl-card__go { color: var(--np-primary); font-size: 12.5px; font-weight: 600; text-decoration: none; white-space: nowrap; }

/* 54.7 下载排行 */
.np-dl-rank { list-style: none; margin: 0; padding: 0; border: 1px solid var(--np-line); border-radius: var(--np-radius); overflow: hidden; }
.np-dl-rank li { display: flex; align-items: center; gap: 12px; padding: 11px 16px; border-bottom: 1px solid var(--np-line); }
.np-dl-rank li:last-child { border-bottom: 0; }
.np-dl-rank__no { flex: 0 0 22px; text-align: center; color: var(--np-muted); font-size: 13px; font-weight: 700; }
.np-dl-rank__no.is-top { color: #fff; background: var(--np-accent); border-radius: var(--np-radius-sm); }
.np-dl-rank__tag { flex: 0 0 auto; padding: 2px 8px; border-radius: var(--np-radius-sm); background: color-mix(in srgb, var(--np-dl-c) 16%, transparent); color: var(--np-dl-c); font-size: 10.5px; font-weight: 800; }
.np-dl-rank li > a { flex: 1 1 auto; min-width: 0; color: var(--np-text); text-decoration: none; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.np-dl-rank li > a:hover { color: var(--np-primary); }
.np-dl-rank__count { flex: 0 0 auto; color: var(--np-muted); font-size: 12px; }

/* 54.8 详情页：类型大图 + 信息表 + 下载按钮 */
.np-dl-single { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 26px; margin: 8px 0 26px; }
.np-dl-single__stage { position: relative; display: flex; align-items: center; justify-content: center; min-height: 300px; padding: 24px; border: 1px solid var(--np-line); border-radius: var(--np-radius); background: color-mix(in srgb, var(--np-dl-c) 7%, var(--np-bg-soft)); }
.np-dl-single__icon { max-width: 150px; max-height: 150px; border-radius: 20px; object-fit: contain; }
.np-dl-single__file { position: relative; display: inline-block; width: 110px; height: 134px; border: 3px solid var(--np-dl-c); border-radius: 10px; background: color-mix(in srgb, var(--np-dl-c) 12%, var(--np-bg)); }
.np-dl-single__file::before { content: ''; position: absolute; top: -3px; right: -3px; width: 34px; height: 34px; border-left: 3px solid var(--np-dl-c); border-bottom: 3px solid var(--np-dl-c); border-radius: 0 0 0 6px; background: var(--np-bg-soft); }
.np-dl-single__file i { position: absolute; left: 20px; right: 20px; top: 60px; height: 4px; border-radius: 2px; background: var(--np-dl-c); box-shadow: 0 15px 0 var(--np-dl-c), 0 30px 0 color-mix(in srgb, var(--np-dl-c) 45%, transparent); }
.np-dl-single__badge { position: absolute; top: 14px; right: 14px; padding: 4px 12px; border-radius: var(--np-radius-sm); background: var(--np-dl-c); color: #fff; font-size: 13px; font-weight: 800; letter-spacing: .5px; }
.np-dl-single__info { min-width: 0; }
.np-dl-single__kind { color: var(--np-dl-c); font-size: 13px; font-weight: 600; }
.np-dl-single__title { margin: 6px 0 16px; font-size: 24px; line-height: 1.35; }
.np-dl-single__specs { width: 100%; border-collapse: collapse; margin-bottom: 20px; }
.np-dl-single__specs th, .np-dl-single__specs td { padding: 8px 0; border-bottom: 1px dashed var(--np-line); text-align: left; font-size: 13px; vertical-align: top; }
.np-dl-single__specs th { width: 88px; color: var(--np-muted); font-weight: 400; white-space: nowrap; }
.np-dl-single__specs td { color: var(--np-text); word-break: break-all; }
.np-dl-single__specs a { color: var(--np-primary); text-decoration: none; }
.np-dl-single__dlhead { display: flex; align-items: center; gap: 8px; margin: 0 0 12px; font-size: 16px; }

.np-dl-buttons { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 10px; }
.np-dl-btn { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid var(--np-line); border-radius: var(--np-radius); background: var(--np-bg); text-decoration: none; transition: var(--np-transition); }
.np-dl-btn:hover { border-color: var(--np-primary); transform: translateY(-1px); }
.np-dl-btn--primary { border-color: var(--np-primary); background: var(--np-primary); }
.np-dl-btn--primary:hover { background: var(--np-primary-dark); border-color: var(--np-primary-dark); }
.np-dl-btn__ico { flex: 0 0 34px; display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px; border-radius: var(--np-radius-sm); background: var(--np-primary-soft); color: var(--np-primary); font-size: 18px; font-weight: 700; }
.np-dl-btn--primary .np-dl-btn__ico { background: rgba(255,255,255,.2); color: #fff; }
.np-dl-btn__txt { display: flex; flex-direction: column; min-width: 0; }
.np-dl-btn__txt strong { color: var(--np-text); font-size: 14px; }
.np-dl-btn__txt small { color: var(--np-muted); font-size: 11.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.np-dl-btn--primary .np-dl-btn__txt strong { color: #fff; }
.np-dl-btn--primary .np-dl-btn__txt small { color: rgba(255,255,255,.82); }

.np-dl-tips { display: flex; flex-wrap: wrap; gap: 10px 20px; margin: 12px 0 0; color: var(--np-text-2); font-size: 13px; }
.np-dl-tips code { padding: 2px 8px; border-radius: var(--np-radius-sm); background: var(--np-bg-soft); color: var(--np-primary); font-size: 13px; user-select: all; }
.np-dl-locked { padding: 18px; border: 1px solid var(--np-line); border-radius: var(--np-radius); background: var(--np-bg-soft); }
.np-dl-locked p { margin: 0 0 12px; color: var(--np-text-2); }
.np-dl-locked .np-dl-btn { display: inline-flex; }
.np-dl-locked .np-dl-btn__txt strong { color: #fff; }

.np-dl-single__lower { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 26px; margin-bottom: 30px; }
.np-dl-single__content { min-width: 0; }
.np-dl-single__content h2 { font-size: 18px; }
.np-dl-panel { padding: 16px; border: 1px solid var(--np-line); border-radius: var(--np-radius); background: var(--np-bg); margin-bottom: 16px; }
.np-dl-panel h3 { margin: 0 0 12px; font-size: 15px; }
.np-dl-related { list-style: none; margin: 0; padding: 0; }
.np-dl-related li { display: flex; align-items: center; gap: 8px; padding: 8px 0; border-bottom: 1px dashed var(--np-line); }
.np-dl-related li:last-child { border-bottom: 0; }
.np-dl-related__tag { flex: 0 0 auto; padding: 2px 6px; border-radius: var(--np-radius-sm); background: color-mix(in srgb, var(--np-dl-c) 16%, transparent); color: var(--np-dl-c); font-size: 10px; font-weight: 800; }
.np-dl-related li > a { flex: 1 1 auto; min-width: 0; color: var(--np-text); text-decoration: none; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.np-dl-related li > a:hover { color: var(--np-primary); }
.np-dl-related li > i { flex: 0 0 auto; color: var(--np-muted); font-size: 11px; font-style: normal; }
.np-dl-back { color: var(--np-primary); font-size: 13px; text-decoration: none; }

/* 54.9 小工具：NP 下载资源 / 分类 / 统计 */
.np-dl-wlist { list-style: none; margin: 0; padding: 0; }
.np-dl-wlist li { display: flex; align-items: center; gap: 10px; padding: 9px 0; border-bottom: 1px dashed var(--np-line); }
.np-dl-wlist li:last-child { border-bottom: 0; }
.np-dl-wlist__tag { flex: 0 0 auto; min-width: 40px; text-align: center; padding: 3px 6px; border-radius: var(--np-radius-sm); background: color-mix(in srgb, var(--np-dl-c) 16%, transparent); color: var(--np-dl-c); font-size: 10px; font-weight: 800; }
.np-dl-wlist__body { flex: 1 1 auto; min-width: 0; }
.np-dl-wlist__title { display: block; color: var(--np-text); text-decoration: none; font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.np-dl-wlist__title:hover { color: var(--np-primary); }
.np-dl-wlist__meta { display: block; margin-top: 2px; color: var(--np-muted); font-size: 11.5px; }
.np-dl-wlist__go { flex: 0 0 auto; color: var(--np-primary); font-size: 12px; text-decoration: none; }
.np-dl-wempty { padding: 20px 0; text-align: center; color: var(--np-muted); font-size: 13px; }

.np-dl-cats { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.np-dl-cats li a { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border: 1px solid var(--np-line); border-radius: var(--np-radius-sm); background: var(--np-bg-soft); text-decoration: none; transition: var(--np-transition); }
.np-dl-cats li a:hover { border-color: var(--np-primary); background: var(--np-primary-soft); }
.np-dl-cats__tag { flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center; width: 26px; height: 26px; border-radius: var(--np-radius-sm); background: var(--np-primary-soft); color: var(--np-primary); font-size: 12px; font-weight: 700; }
.np-dl-cats__name { flex: 1 1 auto; min-width: 0; color: var(--np-text); font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.np-dl-cats__count { flex: 0 0 auto; color: var(--np-muted); font-size: 11.5px; }

.np-dl-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.np-dl-stats > div { padding: 14px 10px; border: 1px solid var(--np-line); border-radius: var(--np-radius); background: var(--np-bg-soft); text-align: center; }
.np-dl-stats b { display: block; color: var(--np-primary); font-size: 21px; line-height: 1.2; }
.np-dl-stats span { display: block; margin-top: 3px; color: var(--np-muted); font-size: 11.5px; }

/* 54.10 响应式：桌面 3~4 列 → 平板 2 列 → 手机 1 列；详情两栏堆叠。 */
@media (max-width: 1100px) {
  .np-dl-grid--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .np-dl-single { grid-template-columns: 240px minmax(0, 1fr); }
  .np-dl-single__lower { grid-template-columns: minmax(0, 1fr) 240px; }
}
@media (max-width: 860px) {
  .np-dl-grid, .np-dl-grid--2, .np-dl-grid--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .np-dl-single { grid-template-columns: 1fr; }
  .np-dl-single__stage { min-height: 200px; }
  .np-dl-single__lower { grid-template-columns: 1fr; }
  .np-dl-hero__stats { width: 100%; justify-content: space-around; }
}
@media (max-width: 560px) {
  .np-dl-grid, .np-dl-grid--2, .np-dl-grid--4 { grid-template-columns: 1fr; }
  .np-dl-hero { padding: 20px 18px; }
  .np-dl-hero__main h1 { font-size: 22px; }
  .np-dl-types { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
  .np-dl-type { flex-direction: column; gap: 6px; padding: 10px 6px; text-align: center; }
  .np-dl-type__label { font-size: 11px; }
  .np-dl-buttons { grid-template-columns: 1fr; }
  .np-dl-rank__count { display: none; }
  .np-dl-sort { gap: 14px; }
}

/* 54.11 论坛方案下的下载中心：卡片 / 表头走论坛的方正小圆角与分区表头语气，
   与第 53 章保持一致（仅在 body.np-preset-forum 时生效）。 */
body.np-preset-forum .np-dl-card,
body.np-preset-forum .np-dl-type,
body.np-preset-forum .np-dl-btn,
body.np-preset-forum .np-dl-panel { border-radius: var(--np-radius-sm); }
body.np-preset-forum .np-dl-sec__head { background: var(--np-bg-soft); padding: 9px 14px; border-bottom: 1px solid var(--np-line); }
body.np-preset-forum .np-dl-sec__head h2 { font-size: 15px; }
body.np-preset-forum .np-dl-rank li { padding: 9px 14px; }
body.np-preset-forum .np-dl-rank li:nth-child(even) { background: var(--np-bg-soft); }
body.np-preset-forum .np-dl-type__badge,
body.np-preset-forum .np-dl-card__tag { border-radius: 2px; }

/* ==========================================================================
   第 55 章 · 商城增强（1.8.68，参考 demo.zibll.com/shop）
   --------------------------------------------------------------------------
   主题原本已有完整的 np_product 交易链，本章只补「卖货的说服力」与
   「逛商城的组件」：促销标签 / 限时倒计时 / 综合评分 / 服务承诺 / 已售角标，
   以及 6 个商城小工具 + 楼层式商城首页。

   三条硬约束（沿用 1.8.60~1.8.67 的教训）：
     1) 全部使用 --np-* 令牌，自动跟随页面样式方案与明暗模式，不写死品牌色；
     2) 不写内联 width / height，网格用容器查询按所在区域宽度收列，
        保证「放哪都行」——侧栏不撑破、全宽区域由第 51 章独占整行；
     3) 所有新元素默认不占位（无数据时不输出 DOM），老商品零回归。
   ========================================================================== */

/* 55.1 商品卡上的角标与促销标签行 ---------------------------------------- */

/* 现有 .np-shop-card__off 在左上、__sold(已售罄) 在右上，
   新增角标落左下、已售数落右下，四角各司其职不重叠。 */
.nps-flags {
  position: absolute;
  left: 8px;
  bottom: 8px;
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  max-width: calc(100% - 16px);
}
.nps-flags__i {
  padding: 2px 7px;
  border-radius: 3px;
  background: var(--np-primary);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  line-height: 1.5;
  white-space: nowrap;
}
.nps-flags__i[data-np-flag="hot"]       { background: #c8383d; }
.nps-flags__i[data-np-flag="new"]       { background: #148a55; }
.nps-flags__i[data-np-flag="discount"]  { background: #b9660f; }
.nps-flags__i[data-np-flag="recommend"] { background: #6d45b8; }

.nps-sold {
  position: absolute;
  right: 8px;
  bottom: 8px;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(12, 17, 24, 0.62);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  line-height: 1.5;
  white-space: nowrap;
}

.nps-promos {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  min-width: 0;
}
.nps-promos__tag {
  padding: 1px 6px;
  border: 1px solid var(--np-primary);
  border-radius: 3px;
  background: var(--np-bg-soft);
  color: var(--np-primary);
  font-size: 11px;
  line-height: 1.6;
  white-space: nowrap;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
}
.nps-promos__tag--lead {
  font-weight: 700;
  border-color: var(--np-accent);
  border-left: 2px solid var(--np-accent);
  color: var(--np-primary);
}

/* 55.2 限时倒计时 --------------------------------------------------------- */
.nps-countdown {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px 12px;
  margin: 10px 0 2px;
  padding: 9px 13px;
  border: 1px solid var(--np-line);
  border-left: 3px solid var(--np-accent);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg-soft);
  font-size: 13px;
}
.nps-countdown__label {
  font-weight: 700;
  color: var(--np-primary);
}
.nps-countdown__clock {
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  letter-spacing: .5px;
  color: var(--np-text);
}
.nps-countdown.is-expired { opacity: .7; }
.nps-countdown.is-expired .nps-countdown__label { color: var(--np-muted); }

/* 详情页里的倒计时与促销标签留出更多呼吸 */
.np-product__info > .nps-promos { margin: 12px 0 0; }
.np-product__info > .nps-countdown { margin: 12px 0 2px; }

/* 55.3 综合评分卡 --------------------------------------------------------- */
.nps-score {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px 22px;
  margin-top: 14px;
  padding: 12px 15px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg-soft);
}
.nps-score__main { display: flex; align-items: baseline; gap: 8px; }
.nps-score__main b {
  font-size: 27px;
  line-height: 1;
  font-weight: 700;
  color: var(--np-primary);
}
.nps-score__main span { font-size: 13px; font-weight: 600; color: var(--np-text-2); }
.nps-score__subs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 18px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.nps-score__subs li {
  display: flex;
  flex-direction: column;
  gap: 1px;
  font-size: 12px;
  color: var(--np-muted);
}
.nps-score__subs b { font-size: 14px; font-weight: 600; color: var(--np-text); }

/* 55.4 服务承诺条 --------------------------------------------------------- */
.nps-promises {
  display: flex;
  flex-wrap: wrap;
  gap: 7px 16px;
  list-style: none;
  margin: 12px 0 0;
  padding: 0;
}
.nps-promises li {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12.5px;
  color: var(--np-text-2);
  min-width: 0;
}
.nps-promises svg { flex: 0 0 auto; color: var(--np-primary); }

/* 55.5 商城商品小工具：按容器宽度自动收列 -------------------------------- */
.nps-goods { container-type: inline-size; min-width: 0; }
.nps-wgrid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  min-width: 0;
}
.nps-goods[data-np-cols="1"] .nps-wgrid { grid-template-columns: minmax(0, 1fr); }
.nps-goods[data-np-cols="2"] .nps-wgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.nps-goods[data-np-cols="3"] .nps-wgrid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.nps-wgrid > .np-shop-card { min-width: 0; }

/* 容器查询：无论放在 300px 侧栏还是 1068px 全宽区域，都自动降到合适列数。
   选择器带属性以压过上面的用户列数设置，特异性相同但书写在后。 */
@container (max-width: 900px) {
  .nps-goods[data-np-cols] .nps-wgrid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@container (max-width: 660px) {
  .nps-goods[data-np-cols] .nps-wgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@container (max-width: 420px) {
  .nps-goods[data-np-cols] .nps-wgrid { grid-template-columns: minmax(0, 1fr); }
  .nps-wgrid .np-shop-card__media { aspect-ratio: 16 / 9; }
}

.nps-wmore {
  display: inline-block;
  margin-top: 12px;
  font-size: 13px;
  font-weight: 600;
  color: var(--np-primary);
}
.nps-wempty {
  padding: 14px;
  border: 1px dashed var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg-soft);
  color: var(--np-muted);
  font-size: 13px;
  line-height: 1.7;
}

/* 55.6 分类图标导航 ------------------------------------------------------- */
.nps-catnav {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 88px), 1fr));
  gap: 14px 8px;
  min-width: 0;
}
.nps-catnav__item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  text-align: center;
  min-width: 0;
}
.nps-catnav__ico {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--nps-cat-c, var(--np-primary));
  color: #fff;
  font-size: 20px;
  font-weight: 700;
  line-height: 1;
  transition: transform var(--np-transition), filter var(--np-transition);
}
.nps-catnav__item:hover .nps-catnav__ico { transform: translateY(-3px); filter: brightness(1.08); }
.nps-catnav--square .nps-catnav__ico { border-radius: 13px; }
.nps-catnav__name {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 600;
  color: var(--np-text);
}
.nps-catnav__count { font-size: 11px; color: var(--np-muted); }

/* 55.7 热销排行 ----------------------------------------------------------- */
.nps-rank {
  display: flex;
  flex-direction: column;
  list-style: none;
  margin: 0;
  padding: 0;
  min-width: 0;
}
.nps-rank__li {
  display: grid;
  grid-template-columns: 22px 46px minmax(0, 1fr);
  align-items: center;
  gap: 9px;
  padding: 8px 2px;
  border-bottom: 1px solid var(--np-line);
  min-width: 0;
}
.nps-rank__li:last-child { border-bottom: 0; }
.nps-rank__no {
  display: grid;
  place-items: center;
  width: 20px;
  height: 20px;
  border-radius: var(--np-radius-sm);
  background: var(--np-bg-soft);
  color: var(--np-muted);
  font-size: 12px;
  font-weight: 700;
}
.nps-rank__li[data-np-rank="1"] .nps-rank__no { background: #c8383d; color: #fff; }
.nps-rank__li[data-np-rank="2"] .nps-rank__no { background: #c97a1e; color: #fff; }
.nps-rank__li[data-np-rank="3"] .nps-rank__no { background: #b08a3e; color: #fff; }
.nps-rank__thumb {
  display: block;
  width: 46px;
  height: 46px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  overflow: hidden;
  background: var(--np-bg-soft);
}
.nps-rank__thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.nps-rank__ph {
  display: block;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, var(--np-bg-soft), var(--np-line));
}
.nps-rank__body { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.nps-rank__title {
  font-size: 13px;
  font-weight: 600;
  color: var(--np-text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.nps-rank__title:hover { color: var(--np-primary); }
.nps-rank__meta { font-size: 11.5px; color: var(--np-muted); }

/* 55.8 迷你购物车 --------------------------------------------------------- */
.nps-minicart { display: flex; flex-direction: column; gap: 11px; min-width: 0; }
.nps-minicart__row {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.nps-minicart__ico {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--np-bg-soft);
  color: var(--np-primary);
}
.nps-minicart__txt { font-size: 13px; color: var(--np-text-2); }
.nps-minicart__txt b { font-size: 18px; color: var(--np-text); }
.nps-minicart__total {
  margin-left: auto;
  font-size: 15px;
  font-weight: 700;
  color: var(--np-primary);
  white-space: nowrap;
}
.nps-minicart__btn {
  display: block;
  padding: 9px 12px;
  border: 1px solid var(--np-primary);
  border-radius: var(--np-radius-sm);
  background: var(--np-primary);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  text-align: center;
}
.nps-minicart__btn:hover { filter: brightness(1.08); color: #fff; }

/* 55.9 商城搜索 ----------------------------------------------------------- */
.nps-search { display: flex; gap: 0; min-width: 0; }
.nps-search__input {
  flex: 1 1 auto;
  min-width: 0;
  padding: 9px 12px;
  border: 1px solid var(--np-line);
  border-right: 0;
  border-radius: var(--np-radius-sm) 0 0 var(--np-radius-sm);
  background: var(--np-bg);
  color: var(--np-text);
  font-size: 13px;
}
.nps-search__input:focus { outline: none; border-color: var(--np-primary); }
.nps-search__btn {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 42px;
  border: 1px solid var(--np-primary);
  border-radius: 0 var(--np-radius-sm) var(--np-radius-sm) 0;
  background: var(--np-primary);
  color: #fff;
  cursor: pointer;
}
.nps-search__hot {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 10px;
  margin-top: 9px;
  font-size: 12px;
  color: var(--np-muted);
}
.nps-search__hot a { color: var(--np-text-2); }
.nps-search__hot a:hover { color: var(--np-primary); }

/* 55.10 商城统计 ---------------------------------------------------------- */
.nps-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 92px), 1fr));
  gap: 10px 8px;
  min-width: 0;
}
.nps-stats > div {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  padding: 10px 4px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg-soft);
  min-width: 0;
}
.nps-stats b {
  font-size: 19px;
  font-weight: 700;
  color: var(--np-primary);
  line-height: 1.2;
}
.nps-stats span {
  font-size: 11.5px;
  color: var(--np-muted);
  text-align: center;
  white-space: nowrap;
}

/* 55.11 楼层式商城首页 ---------------------------------------------------- */
.nps-home { padding-bottom: 30px; }
.nps-home__hero { margin-bottom: 22px; }
.nps-home__cats { margin: 22px 0 26px; }
.nps-home__service { margin: 0 0 8px; }
.nps-sec__title {
  display: flex;
  align-items: center;
  margin: 0 0 14px;
  font-size: 18px;
  font-weight: 700;
  color: var(--np-text);
}
.nps-sec__title span { position: relative; padding-left: 12px; }
.nps-sec__title span::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 16px;
  border-radius: 2px;
  background: var(--np-primary);
}
.nps-floor { margin: 28px 0; }
.nps-floor__head {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 6px 14px;
  margin-bottom: 15px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--np-primary);
}
.nps-floor__title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  font-size: 19px;
  font-weight: 700;
  color: var(--np-text);
}
.nps-floor__mark {
  display: block;
  width: 6px;
  height: 18px;
  border-radius: 2px;
  background: var(--np-primary);
}
.nps-floor__sub { font-size: 12.5px; color: var(--np-muted); }
.nps-floor__more {
  margin-left: auto;
  font-size: 13px;
  font-weight: 600;
  color: var(--np-primary);
  white-space: nowrap;
}
.nps-floor--promo .nps-floor__head { border-bottom-color: var(--np-accent); }
.nps-floor--promo .nps-floor__mark { background: var(--np-accent); }
.nps-floor--promo .nps-floor__more { color: var(--np-primary); }
.nps-home__bottom {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.35fr);
  gap: 24px;
  margin: 32px 0 18px;
}
.nps-home__rank, .nps-home__new { min-width: 0; }
.nps-home__new-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  min-width: 0;
}
.nps-home__new-grid > .np-shop-card { min-width: 0; }
.nps-home__all { margin-top: 22px; text-align: center; }

/* 55.12 手机适配（375 / 560 断点） ---------------------------------------- */
@media (max-width: 900px) {
  .nps-home__bottom { grid-template-columns: minmax(0, 1fr); }
}
/* 375px 商城卡片单列：主题原有 560px 断点是 2 列（卡片仅 150px），
   促销标签 / 角标 / 价格会被挤成两行，这里在 420px 以下收紧为单列。 */
@media (max-width: 420px) {
  .np-shop-grid,
  .np-shop-grid--2,
  .np-shop-grid--3,
  .np-shop-grid--4,
  .nps-home__new-grid { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 560px) {
  .nps-home__new-grid { grid-template-columns: minmax(0, 1fr); }
  .nps-floor__head { gap: 4px 10px; }
  .nps-floor__title { font-size: 17px; }
  .nps-floor__more { margin-left: 0; }
  .nps-catnav { grid-template-columns: repeat(auto-fill, minmax(min(100%, 72px), 1fr)); gap: 12px 4px; }
  .nps-catnav__ico { width: 46px; height: 46px; font-size: 18px; }
  .nps-catnav__name { font-size: 12px; }
  .nps-score { gap: 10px 16px; padding: 11px 12px; }
  .nps-score__main b { font-size: 24px; }
  .nps-countdown { font-size: 12.5px; padding: 8px 11px; }
  .nps-minicart__total { font-size: 14px; }
}

/* 55.13 页面样式方案兼容 -------------------------------------------------- */
/* 导购商城方案：橙金主色，楼层头与分类图标自动跟随，只需把方正小圆角压平一点 */
body.np-preset-shop .nps-floor__mark,
body.np-preset-shop .nps-sec__title span::before { border-radius: 1px; }
/* 论坛社区方案：沿用第 53 章的分区表头语气，方正小圆角 + 斑马纹 */
body.np-preset-forum .nps-score,
body.np-preset-forum .nps-countdown,
body.np-preset-forum .nps-stats > div,
body.np-preset-forum .nps-catnav--square .nps-catnav__ico { border-radius: var(--np-radius-sm); }
body.np-preset-forum .nps-floor__head { background: var(--np-bg-soft); padding: 9px 14px; border-bottom: 1px solid var(--np-line); }
body.np-preset-forum .nps-rank__li:nth-child(even) { background: var(--np-bg-soft); }
/* 深色模式下的实底角标：令牌已覆盖底色，这里只保证半透明遮罩依然压得住图 */
body.np-dark .nps-sold { background: rgba(0, 0, 0, 0.66); }

/* ==========================================================================
   第 56 章 · 论坛社区 2.0（1.8.69，参考 zibll.top / 子比）
   --------------------------------------------------------------------------
   1.8.67 的第 53 章是照 52pojie 的 Discuz 表格做的：白底 1px 细线、
   斑马纹、每行一个「帖」字小方块、方块分类 chip，真机看偏「旧」。
   本章用同等选择器特异性 + 后写覆盖，把论坛方案整体换成子比式
   现代社区卡片版：浅灰页底 + 白色圆角卡片 + 柔和阴影浮起 + 彩色
   渐变板块图标 + 圆形头像 + 胶囊标签 + 单列主题卡片流。

   三条硬约束（沿用 1.8.60~1.8.68 的教训）：
     1) 换肤规则全部带 body.np-preset-forum 前缀，其它 8 套方案零影响；
        .npf-* 组件规则不依赖方案，可在任意页面样式下使用；
     2) 顶栏文字 / 按钮体系保持不动，只加一条顶边，避免 1.8.60 深色
        顶栏三条杠不可见的历史缺陷；
     3) 颜色走 --np-* 令牌，明暗由 body.np-dark 再覆盖；板块 5 色渐变
        是装饰色，不承载小字正文，避免对比度不达标。
   ========================================================================== */

/* 56.1 论坛私有令牌与页面底 ------------------------------------------------ */
:root {
  --npf-page: #f4f6fa;
  --npf-shadow: 0 1px 2px rgba(16, 24, 40, 0.04), 0 6px 20px rgba(16, 24, 40, 0.06);
  --npf-shadow-hover: 0 4px 10px rgba(16, 24, 40, 0.07), 0 14px 34px rgba(16, 24, 40, 0.10);
}
body.np-dark {
  --npf-page: #10141a;
  --npf-shadow: 0 1px 2px rgba(0, 0, 0, 0.30), 0 6px 20px rgba(0, 0, 0, 0.28);
  --npf-shadow-hover: 0 4px 10px rgba(0, 0, 0, 0.40), 0 14px 34px rgba(0, 0, 0, 0.42);
}
/* 浅灰页底让白色卡片浮起来，这是子比「层次感」的来源；卡片仍用 --np-bg 白。 */
body.np-preset-forum { background: var(--npf-page); }
body.np-dark.np-preset-forum { background: var(--npf-page); }

/* 板块 / 标签 5 色装饰渐变（蓝 / 青绿 / 堇紫 / 暖橙 / 玫红）。 */
.npf-c--0 { --npf-c1: #4f6ef7; --npf-c2: #7a5cf0; --npf-cs: rgba(79, 110, 247, 0.28); }
.npf-c--1 { --npf-c1: #14a37b; --npf-c2: #0e9aa8; --npf-cs: rgba(20, 163, 123, 0.26); }
.npf-c--2 { --npf-c1: #8250df; --npf-c2: #b458d8; --npf-cs: rgba(130, 80, 223, 0.26); }
.npf-c--3 { --npf-c1: #e08a24; --npf-c2: #dc5c3c; --npf-cs: rgba(224, 138, 36, 0.26); }
.npf-c--4 { --npf-c1: #e25684; --npf-c2: #d0406a; --npf-cs: rgba(226, 86, 132, 0.26); }

/* 56.2 顶边与导航：只点题，不动顶栏文字体系；导航悬停从蓝底块改柔和胶囊。 */
body.np-preset-forum .np-header { border-top: 3px solid var(--np-primary); }
body.np-preset-forum .np-nav a:hover,
body.np-preset-forum .np-nav .current-menu-item > a,
body.np-preset-forum .np-nav .current-menu-ancestor > a {
  color: var(--np-primary);
  background: var(--np-primary-soft);
  border-radius: 999px;
}
body.np-dark.np-preset-forum .np-nav a:hover,
body.np-dark.np-preset-forum .np-nav .current-menu-item > a,
body.np-dark.np-preset-forum .np-nav .current-menu-ancestor > a {
  color: var(--np-primary);
  background: var(--np-primary-soft);
}

/* 56.3 小工具：从「浅蓝表格表头」改回现代白卡 + 柔和阴影 + 渐变短条。 */
body.np-preset-forum .np-widget {
  padding: 20px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
  box-shadow: var(--npf-shadow);
}
body.np-preset-forum .np-widget__title {
  margin: 0 0 16px;
  padding: 0 0 12px;
  border-bottom: 1px solid var(--np-line);
  background: none;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0;
}
body.np-dark.np-preset-forum .np-widget__title { background: none; }
body.np-preset-forum .np-widget__title::before {
  width: 4px;
  height: 16px;
  border-radius: 3px;
  background: linear-gradient(180deg, var(--np-primary), var(--np-primary-dark));
}

/* 56.4 分类 chip：方块改胶囊白卡 + 彩色圆点（呼应子比板块图标）。 */
body.np-preset-forum .np-cats { gap: 10px; }
body.np-preset-forum .np-cat {
  padding: 8px 15px;
  border: 1px solid var(--np-line);
  border-radius: 999px;
  background: var(--np-bg);
  box-shadow: var(--npf-shadow);
  font-size: 13.5px;
}
body.np-preset-forum .np-cat:hover {
  transform: translateY(-1px);
  border-color: var(--np-primary);
  background: var(--np-bg);
  color: var(--np-primary);
}
body.np-preset-forum .np-cat.is-active { border-color: transparent; background: var(--np-primary); color: #fff; }
body.np-dark.np-preset-forum .np-cat.is-active { color: #10141a; }
body.np-preset-forum .np-cat__dot { width: 8px; height: 8px; border-radius: 50%; background: var(--np-primary); }
body.np-preset-forum .np-cat:nth-child(5n + 1) .np-cat__dot { background: #4f6ef7; }
body.np-preset-forum .np-cat:nth-child(5n + 2) .np-cat__dot { background: #14a37b; }
body.np-preset-forum .np-cat:nth-child(5n + 3) .np-cat__dot { background: #8250df; }
body.np-preset-forum .np-cat:nth-child(5n + 4) .np-cat__dot { background: #e08a24; }
body.np-preset-forum .np-cat:nth-child(5n + 5) .np-cat__dot { background: #e25684; }

/* 56.5 主题列表：从「1px 细线表格 + 斑马纹」重排成单列白色卡片流。 */
body.np-preset-forum .np-post-list {
  display: grid;
  gap: 16px;
  border: 0;
  border-radius: 0;
  overflow: visible;
}
body.np-preset-forum .np-post-item {
  position: relative;
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 0 14px;
  align-items: start;
  padding: 20px 22px;
  margin: 0;
  border: 1px solid var(--np-line);
  border-bottom: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
  box-shadow: var(--npf-shadow);
  transition: transform 200ms ease, box-shadow 200ms ease;
}
body.np-preset-forum .np-post-item:last-child { padding-bottom: 20px; }
body.np-preset-forum .np-post-item:nth-child(even) { background: var(--np-bg); }
body.np-dark.np-preset-forum .np-post-item:nth-child(even) { background: var(--np-bg); }
body.np-preset-forum .np-post-item:hover {
  transform: translateY(-2px);
  background: var(--np-bg);
  box-shadow: var(--npf-shadow-hover);
}
body.np-dark.np-preset-forum .np-post-item:hover {
  background: var(--np-bg);
  box-shadow: var(--npf-shadow-hover);
}

/* 帖子类型徽标：34px 方块 → 44px 圆角彩色渐变，5 色轮转。 */
body.np-preset-forum .np-post-item__thumb {
  grid-column: 1;
  grid-row: 1;
  width: 44px;
  height: 44px;
  aspect-ratio: auto;
  min-height: 0;
  border: 0;
  border-radius: 13px;
  background: linear-gradient(135deg, #4f6ef7, #7a5cf0);
  box-shadow: 0 5px 14px rgba(79, 110, 247, 0.26);
  overflow: hidden;
}
body.np-preset-forum .np-post-item:nth-child(5n + 2) .np-post-item__thumb { background: linear-gradient(135deg, #14a37b, #0e9aa8); box-shadow: 0 5px 14px rgba(20, 163, 123, 0.24); }
body.np-preset-forum .np-post-item:nth-child(5n + 3) .np-post-item__thumb { background: linear-gradient(135deg, #8250df, #b458d8); box-shadow: 0 5px 14px rgba(130, 80, 223, 0.24); }
body.np-preset-forum .np-post-item:nth-child(5n + 4) .np-post-item__thumb { background: linear-gradient(135deg, #e08a24, #dc5c3c); box-shadow: 0 5px 14px rgba(224, 138, 36, 0.24); }
body.np-preset-forum .np-post-item:nth-child(5n + 5) .np-post-item__thumb { background: linear-gradient(135deg, #e25684, #d0406a); box-shadow: 0 5px 14px rgba(226, 86, 132, 0.24); }
body.np-preset-forum .np-post-item__thumb img { display: none; }
body.np-preset-forum .np-post-item__thumb::after {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.22), transparent 72%);
}
body.np-preset-forum .np-post-item__thumb::before {
  content: '帖';
  position: absolute;
  inset: 0;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  font-weight: 700;
  color: #fff;
}
body.np-preset-forum .np-post-item__thumb--empty { display: block; }

/* 置顶标：模板里 badge 位于 thumb 内，这里隐藏它，改用卡片右上角胶囊。
   post_class() 会给置顶文章加 .sticky，语义准确且不依赖 DOM 位置。 */
body.np-preset-forum .np-post-item__badge { display: none; }
body.np-preset-forum .np-post-item.sticky::before {
  content: '置顶';
  position: absolute;
  right: 18px;
  top: 18px;
  z-index: 3;
  padding: 3px 11px;
  border-radius: 999px;
  background: var(--np-accent);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .3px;
}

/* 内容列：作者行置顶 → 大标题 → 摘要，模拟子比帖子卡片的信息层级。 */
body.np-preset-forum .np-post-item__body {
  grid-column: 2;
  grid-row: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
}
body.np-preset-forum .np-post-item .np-post-meta {
  order: -1;
  grid-column: auto;
  grid-row: auto;
  margin: 0 0 9px;
  gap: 10px;
  font-size: 12.5px;
}
body.np-preset-forum .np-post-meta__avatar { width: 20px; height: 20px; border-radius: 50%; }
body.np-preset-forum .np-post-item__title {
  order: 0;
  margin: 0 0 8px;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.45;
}
body.np-preset-forum .np-post-item__title a { display: inline; -webkit-line-clamp: unset; overflow: visible; }
body.np-preset-forum .np-post-item__title a:hover { color: var(--np-primary); }
body.np-preset-forum .np-post-item__excerpt {
  order: 1;
  display: -webkit-box;
  margin: 0;
  font-size: 14px;
  line-height: 1.7;
  color: var(--np-text-2);
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  white-space: normal;
  overflow: hidden;
}

/* 56.6 汇总：覆盖第 53 / 55 章残留的 Discuz 表格语气。 */
body.np-preset-forum .np-content,
body.np-preset-forum .np-main { background: transparent; }
body.np-preset-forum .np-dl-card,
body.np-preset-forum .np-dl-type,
body.np-preset-forum .np-dl-btn,
body.np-preset-forum .np-dl-panel { border-radius: var(--np-radius-sm); box-shadow: var(--npf-shadow); }
body.np-preset-forum .np-dl-sec__head {
  padding: 0 0 12px;
  border-bottom: 1px solid var(--np-line);
  background: none;
}
body.np-preset-forum .np-dl-rank li:nth-child(even) { background: transparent; }
body.np-preset-forum .nps-floor__head { padding: 0; border: 0; background: none; }
body.np-preset-forum .nps-rank__li:nth-child(even) { background: transparent; }
body.np-preset-forum .nps-score,
body.np-preset-forum .nps-countdown,
body.np-preset-forum .nps-stats > div { border-radius: var(--np-radius-sm); }

/* 56.7 手机端：覆盖第 53.7 节的 28px 方块行，保持卡片流单列、标题不裁切。 */
@media (max-width: 640px) {
  body.np-preset-forum .np-post-item { grid-template-columns: 38px minmax(0, 1fr); gap: 0 12px; padding: 16px; }
  body.np-preset-forum .np-post-item__thumb { width: 38px; height: 38px; border-radius: 11px; }
  body.np-preset-forum .np-post-item__thumb::before { font-size: 14px; }
  body.np-preset-forum .np-post-item .np-post-meta { grid-column: auto; grid-row: auto; gap: 8px; font-size: 11.5px; }
  body.np-preset-forum .np-post-item__body { grid-column: 2; grid-row: 1; }
  body.np-preset-forum .np-post-item__title { font-size: 16.5px; }
  body.np-preset-forum .np-widget { padding: 16px; }
  body.np-preset-forum .np-widget__title { margin: 0 0 13px; padding: 0 0 10px; }
  body.np-preset-forum .np-post-item.sticky::before { right: 14px; top: 14px; }
}

/* 56.8 通用零件：按钮 / 图标 / 头像 / 标签 / 面包屑 / 区块头 / 分页 ----- */
.npf-ico { width: 14px; height: 14px; flex: 0 0 14px; display: inline-block; vertical-align: -2px; }
.npf-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 10px 20px;
  border: 1px solid var(--np-line);
  border-radius: 999px;
  background: var(--np-bg);
  color: var(--np-text);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease;
}
.npf-btn:hover { transform: translateY(-1px); box-shadow: var(--npf-shadow); color: var(--np-primary); }
.npf-btn--primary { border-color: transparent; background: var(--np-primary); color: #fff; box-shadow: 0 6px 18px var(--np-primary-soft); }
.npf-btn--primary:hover { color: #fff; }
body.np-dark .npf-btn--primary { color: #10141a; }
body.np-dark .npf-btn--primary:hover { color: #10141a; }
.npf-btn--block { display: flex; }

.npf-avatar {
  position: relative;
  flex: 0 0 38px;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  overflow: hidden;
  background: linear-gradient(135deg, var(--np-primary), var(--np-primary-dark));
}
.npf-avatar__img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; }
.npf-avatar__fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  color: #fff;
  font-size: 15px;
  font-weight: 700;
}
.npf-avatar--lg { flex-basis: 48px; width: 48px; height: 48px; border: 3px solid var(--np-bg); box-sizing: content-box; }
.npf-avatar--lg .npf-avatar__fallback { font-size: 17px; }

.npf-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 11px;
  border-radius: 999px;
  background: var(--np-bg-soft);
  color: var(--np-text-2);
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  transition: background 180ms ease, color 180ms ease;
}
.npf-tag::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--npf-c1, var(--np-primary)); }
.npf-tag:hover { background: var(--np-primary-soft); color: var(--np-primary); }
.npf-tag--plain { font-weight: 500; }
.npf-tags { display: flex; flex-wrap: wrap; gap: 8px; }

.npf-crumb { display: flex; align-items: center; gap: 8px; padding: 16px 0 0; font-size: 13px; color: var(--np-muted); }
.npf-crumb a { color: var(--np-muted); text-decoration: none; }
.npf-crumb a:hover { color: var(--np-primary); }
.npf-crumb__sep { opacity: .55; }
.npf-crumb__cur { color: var(--np-text-2); }

.npf-empty {
  padding: 30px 18px;
  border: 1px dashed var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
  color: var(--np-muted);
  font-size: 14px;
  text-align: center;
}
.npf-empty a { color: var(--np-primary); }

.npf-sec { margin: 26px 0; }
.npf-sec__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.npf-sec__title { display: flex; align-items: center; gap: 9px; margin: 0; font-size: 20px; font-weight: 800; color: var(--np-text); }
.npf-sec__title::before { content: ''; width: 5px; height: 20px; border-radius: 3px; background: linear-gradient(180deg, var(--np-primary), var(--np-primary-dark)); }
.npf-sec__sub { font-size: 13px; color: var(--np-muted); white-space: nowrap; }

.npf-pages { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; margin-top: 22px; }
.npf-pages__i {
  padding: 7px 13px;
  border: 1px solid var(--np-line);
  border-radius: 9px;
  background: var(--np-bg);
  color: var(--np-text-2);
  font-size: 13px;
  text-decoration: none;
}
.npf-pages__i:hover { border-color: var(--np-primary); color: var(--np-primary); }
.npf-pages__i.is-active { border-color: transparent; background: var(--np-primary); color: #fff; font-weight: 700; }
body.np-dark .npf-pages__i.is-active { color: #10141a; }

/* 56.9 Hero 与统计条 ------------------------------------------------------ */
.npf-hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 28px;
  margin: 18px 0 0;
  padding: 32px 34px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: linear-gradient(120deg, var(--np-primary-soft), transparent 62%), var(--np-bg);
  box-shadow: var(--npf-shadow);
  overflow: hidden;
}
.npf-hero::before {
  content: '';
  position: absolute;
  right: -90px;
  top: -130px;
  width: 340px;
  height: 340px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--np-primary-soft), transparent 68%);
  pointer-events: none;
}
.npf-hero__main { position: relative; z-index: 1; min-width: 0; }
.npf-hero__eyebrow { display: inline-block; margin-bottom: 10px; font-size: 11.5px; font-weight: 700; letter-spacing: 1.4px; color: var(--np-primary); }
.npf-hero__title { margin: 0 0 10px; font-size: 32px; font-weight: 800; line-height: 1.25; color: var(--np-text); }
.npf-hero__desc { max-width: 580px; margin: 0 0 18px; font-size: 14.5px; line-height: 1.75; color: var(--np-text-2); }
.npf-hero__actions { display: flex; flex-wrap: wrap; gap: 10px; }

.npf-stats { position: relative; z-index: 1; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; min-width: 268px; }
.npf-stats__i {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg);
}
.npf-stats__ico { display: inline-flex; align-items: center; justify-content: center; flex: 0 0 30px; width: 30px; height: 30px; border-radius: 9px; background: var(--np-primary-soft); color: var(--np-primary); }
.npf-stats__ico .npf-ico { width: 16px; height: 16px; }
.npf-stats__txt { display: flex; flex-direction: column; min-width: 0; }
.npf-stats__txt b { font-size: 18px; font-weight: 800; line-height: 1.2; color: var(--np-text); }
.npf-stats__txt small { font-size: 11.5px; color: var(--np-muted); }
.npf-stats--compact { min-width: 0; }
.npf-stats--compact .npf-stats__i { padding: 10px 12px; }
.npf-stats--compact .npf-stats__txt b { font-size: 16px; }

/* 56.10 胶囊 Tab 与公告条 ------------------------------------------------- */
.npf-tabs {
  display: flex;
  gap: 6px;
  margin: 18px 0;
  padding: 6px;
  border: 1px solid var(--np-line);
  border-radius: 999px;
  background: var(--np-bg);
  box-shadow: var(--npf-shadow);
  overflow-x: auto;
  scrollbar-width: none;
}
.npf-tabs::-webkit-scrollbar { display: none; }
.npf-tabs__i {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 16px;
  border-radius: 999px;
  color: var(--np-text-2);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  transition: background 180ms ease, color 180ms ease;
}
.npf-tabs__i:hover { background: var(--np-primary-soft); color: var(--np-primary); }
.npf-tabs__i.is-active { background: var(--np-primary); color: #fff; }
body.np-dark .npf-tabs__i.is-active { color: #10141a; }
.npf-tabs__i .npf-ico { width: 15px; height: 15px; }

.npf-notice {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 4px;
  padding: 12px 16px;
  border: 1px solid var(--np-line);
  border-left: 3px solid var(--np-accent);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg);
  font-size: 13.5px;
  color: var(--np-text-2);
}
.npf-notice__tag { flex: 0 0 auto; padding: 2px 9px; border-radius: 999px; background: var(--np-accent); color: #fff; font-size: 11px; font-weight: 700; }
.npf-notice__txt { min-width: 0; }

/* 56.11 板块卡片墙 -------------------------------------------------------- */
.npf-boards { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 258px), 1fr)); }
.npf-board {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  padding: 16px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
  box-shadow: var(--npf-shadow);
  color: var(--np-text);
  text-decoration: none;
  transition: transform 200ms ease, box-shadow 200ms ease, border-color 200ms ease;
}
.npf-board:hover { transform: translateY(-3px); border-color: var(--npf-c1); box-shadow: var(--npf-shadow-hover); color: var(--np-text); }
.npf-board__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 46px;
  width: 46px;
  height: 46px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--npf-c1), var(--npf-c2));
  box-shadow: 0 5px 14px var(--npf-cs);
  color: #fff;
  font-size: 19px;
  font-weight: 800;
}
.npf-board__glyph { line-height: 1; }
.npf-board__body { display: flex; flex-direction: column; gap: 3px; flex: 1 1 auto; min-width: 0; }
.npf-board__name { font-size: 15px; font-weight: 700; color: var(--np-text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.npf-board__desc { font-size: 12.5px; color: var(--np-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.npf-board__count { display: flex; flex-direction: column; align-items: center; flex: 0 0 auto; }
.npf-board__count b { font-size: 16px; font-weight: 800; color: var(--np-text); }
.npf-board__count small { font-size: 11px; color: var(--np-muted); }
.npf-board__arrow { display: inline-flex; flex: 0 0 auto; color: var(--np-muted); }
.npf-board__arrow .npf-ico { width: 13px; height: 13px; }
.npf-board--compact { padding: 13px; }
.npf-board--compact .npf-board__icon { flex-basis: 40px; width: 40px; height: 40px; border-radius: 12px; font-size: 17px; }
.npf-board--compact .npf-board__name { font-size: 14px; }

/* 56.12 主题卡片流 / 布局 / 侧栏 ----------------------------------------- */
.npf-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 22px; align-items: start; margin: 26px 0 10px; }
.npf-layout--full { grid-template-columns: minmax(0, 1fr); }
.npf-main { min-width: 0; }
.npf-feed { display: grid; gap: 16px; }

.npf-post {
  min-width: 0;
  padding: 20px 22px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
  box-shadow: var(--npf-shadow);
  transition: transform 200ms ease, box-shadow 200ms ease;
}
.npf-post:hover { transform: translateY(-2px); box-shadow: var(--npf-shadow-hover); }
.npf-post__head { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.npf-post__byline { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.npf-post__author { font-size: 14px; font-weight: 700; color: var(--np-text); text-decoration: none; }
.npf-post__author:hover { color: var(--np-primary); }
.npf-post__time { font-size: 12px; color: var(--np-muted); }
.npf-post__time i { margin: 0 5px; font-style: normal; opacity: .6; }
.npf-post__pin { margin-left: auto; padding: 3px 10px; border-radius: 999px; background: var(--np-accent); color: #fff; font-size: 11px; font-weight: 700; }
.npf-post__title { margin: 0 0 8px; font-size: 19px; font-weight: 700; line-height: 1.45; }
.npf-post__title a { color: var(--np-text); text-decoration: none; }
.npf-post__title a:hover { color: var(--np-primary); }
.npf-post__excerpt { margin: 0 0 12px; font-size: 14px; line-height: 1.75; color: var(--np-text-2); }
.npf-post__thumb { display: block; margin: 0 0 12px; border-radius: 10px; overflow: hidden; }
.npf-post__thumb img { display: block; width: 100%; max-height: 230px; object-fit: cover; }
.npf-post__foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding-top: 12px; border-top: 1px solid var(--np-line); }
.npf-post__ops { display: flex; align-items: center; gap: 14px; }
.npf-op { display: inline-flex; align-items: center; gap: 5px; color: var(--np-muted); font-size: 12.5px; text-decoration: none; }
.npf-op--share:hover { color: var(--np-primary); }

.npf-side { display: grid; gap: 16px; min-width: 0; }
.npf-panel {
  padding: 18px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
  box-shadow: var(--npf-shadow);
}
.npf-panel--welcome { padding: 0; overflow: hidden; }
.npf-panel__title { display: flex; align-items: center; gap: 8px; margin: 0 0 14px; font-size: 15px; font-weight: 700; color: var(--np-text); }
.npf-panel__title::before { content: ''; width: 4px; height: 15px; border-radius: 3px; background: linear-gradient(180deg, var(--np-primary), var(--np-primary-dark)); }

.npf-rank { list-style: none; margin: 0; padding: 0; }
.npf-rank__li { display: flex; align-items: center; gap: 10px; padding: 9px 0; border-bottom: 1px dashed var(--np-line); }
.npf-rank__li:last-child { border-bottom: 0; }
.npf-rank__no { display: inline-flex; align-items: center; justify-content: center; flex: 0 0 21px; width: 21px; height: 21px; border-radius: 6px; background: var(--np-bg-soft); color: var(--np-muted); font-size: 12px; font-weight: 700; }
.npf-rank__no--top { background: var(--np-primary); color: #fff; }
body.np-dark .npf-rank__no--top { color: #10141a; }
.npf-rank__title { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--np-text); font-size: 13.5px; text-decoration: none; }
.npf-rank__title:hover { color: var(--np-primary); }
.npf-rank__meta { display: inline-flex; align-items: center; gap: 4px; flex: 0 0 auto; color: var(--np-muted); font-size: 12px; }

.npf-welcome__cover { height: 62px; background: linear-gradient(120deg, var(--np-primary), var(--np-primary-dark)); }
.npf-welcome__user { position: relative; display: flex; align-items: center; gap: 10px; margin: -24px 16px 14px; }
.npf-welcome__hi { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.npf-welcome__hi b { font-size: 14.5px; font-weight: 700; color: var(--np-text); }
.npf-welcome__hi small { font-size: 12px; color: var(--np-muted); }
.npf-panel--welcome .npf-btn--block { margin: 0 16px 16px; }

/* 56.13 论坛小工具：网格按容器宽度自动收列，侧栏不撑破、全宽由第 51 章独占整行。 */
.npf-wboards { display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 218px), 1fr)); }
.npf-wboards[data-npf-cols="1"] { grid-template-columns: minmax(0, 1fr); }
.npf-wboards[data-npf-cols="3"] { grid-template-columns: repeat(auto-fill, minmax(min(100%, 178px), 1fr)); }
.npf-wstats { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 258px), 1fr)); align-items: start; }
.npf-wstats .npf-welcome { border: 1px solid var(--np-line); border-radius: var(--np-radius); background: var(--np-bg); overflow: hidden; }
.npf-set-hint { padding: 14px 16px; border: 1px solid var(--np-line); border-left: 3px solid var(--np-primary); border-radius: 8px; background: var(--np-bg-soft); }

/* 56.14 暗色与响应式 ------------------------------------------------------ */
body.np-dark .npf-board__icon { box-shadow: 0 5px 16px rgba(0, 0, 0, 0.34); }
body.np-dark .npf-hero { background: linear-gradient(120deg, var(--np-primary-soft), transparent 62%), var(--np-bg); }
body.np-dark .npf-stats__i,
body.np-dark .npf-btn:not(.npf-btn--primary) { background: var(--np-bg-soft); }
/* 主按钮必须保留主色实底，否则暗色下会退化成「深底 + 深字」不可读。 */
body.np-dark .npf-btn--primary { background: var(--np-primary); color: #10141a; }
body.np-dark .npf-hero .npf-stats__i { background: var(--np-bg); }

@media (max-width: 1100px) {
  .npf-boards { grid-template-columns: repeat(auto-fill, minmax(min(100%, 232px), 1fr)); }
}
@media (max-width: 900px) {
  .npf-hero { grid-template-columns: minmax(0, 1fr); gap: 20px; padding: 26px; }
  .npf-stats { min-width: 0; grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .npf-layout { grid-template-columns: minmax(0, 1fr); }
  .npf-side { grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); }
}
@media (max-width: 640px) {
  .npf-hero { padding: 22px 18px; }
  .npf-hero__title { font-size: 26px; }
  .npf-hero__desc { font-size: 13.5px; }
  .npf-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .npf-tabs { margin: 14px 0; padding: 5px; }
  .npf-tabs__i { padding: 8px 13px; font-size: 13px; }
  .npf-boards { grid-template-columns: minmax(0, 1fr); }
  .npf-sec { margin: 20px 0; }
  .npf-sec__title { font-size: 18px; }
  .npf-post { padding: 16px; }
  .npf-post__title { font-size: 17px; }
  .npf-post__foot { flex-wrap: wrap; }
  .npf-layout { margin-top: 20px; }
  .npf-crumb { padding-top: 12px; }
}

/* ==========================================================================
   第 57 章 · 组件功能迁移到小工具（1.8.70）
   --------------------------------------------------------------------------
   1.8.70 把主题设置里几块「可独立摆放的内容组件」搬进「外观 → 小工具」：
   NP 作者信息卡 / NP 相关文章 / NP 文章互动条，并给 NP · 最近动态 补齐
   实例字段。本章只针对三个新挂件输出的 .np-mig 包装写规则，全部是新类名、
   纯末尾追加，不覆盖任何既有选择器 —— 未拖新挂件的站点与 1.8.69 逐像素一致。

   57.1 挂件在小工具卡内的基础排版
   57.2 互动条 / 作者卡 / 相关文章的间距收敛
   57.3 相关文章在窄区域自动收列
   57.4 手机端
   ========================================================================== */

/* 57.1 基础：窄侧栏里不撑破卡片。
   同时把包装建立为「内联尺寸查询容器」，57.3 才能按挂件自身宽度收列；
   若没有 container-type，@container 无祖先容器可查询，规则会静默失效。 */
.np-mig { min-width: 0; max-width: 100%; container-type: inline-size; }

/* 57.2 小工具卡自带内边距，组件原有的上下外边距归零，避免双重留白。
   .np-pa 原本有 30px 上边距（正文末尾的呼吸感），放进白卡里显得过空。 */
.np-mig--authorbox .np-author-box,
.np-mig--related .np-post-grid,
.np-mig--postactions .np-pa { margin-top: 0; margin-bottom: 0; }
.np-mig--postactions .np-pa { max-width: 100%; }

/* 57.3 相关文章放进 320px 侧栏时自动收列。
   用 html body ... [data-np-cols] 提权，盖过第 48 章的列数规则。 */
@container (max-width: 520px) {
  html body .np-mig--related .np-post-grid[data-np-cols] { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@container (max-width: 360px) {
  html body .np-mig--related .np-post-grid[data-np-cols] { grid-template-columns: minmax(0, 1fr); }
}

/* 57.4 手机端一律单列。 */
@media (max-width: 600px) {
  html body .np-mig--related .np-post-grid[data-np-cols] { grid-template-columns: minmax(0, 1fr); }
  .np-mig--postactions .np-pa__bar { flex-wrap: wrap; }
}

/* ==========================================================================
   第 58 章 · 1.8.71 参考 demo.zibll.com 补齐 8 个小工具 + 模块入场动画
   --------------------------------------------------------------------------
   对照子比官方「模块明细」补齐：分类专题聚合、文章 mini、用户排行榜、
   图文视频封面、画廊、超级视频 / 嵌入、一言、合作伙伴。本章只命中新增的
   .npm-* 类名与 [data-np-anim]，全部纯末尾追加，不覆盖任何既有选择器。

   58.1  通用：.npm-root 是内联尺寸查询容器，按挂件自身宽度适配
   58.2  分类聚合            58.3  文章 Mini 榜
   58.4  用户排行榜          58.5  图文封面
   58.6  图库宫格            58.7  视频与嵌入
   58.8  一句话              58.9  滚动友链
   58.10 模块入场动画（默认关闭）
   58.11 双端适配（容器查询 / 视口 / 减少动效）
   ========================================================================== */

/* 58.1 通用 --------------------------------------------------------------- */
.npm-root {
  min-width: 0;
  max-width: 100%;
  container-type: inline-size;
  color: var(--np-text);
  font-size: 14px;
}
.npm-root a { color: inherit; }
.npm-root img,
.npm-root video { max-width: 100%; }
.npm-root strong { font-weight: 600; }

/* 58.2 分类聚合：封面头 + 下属文章列表 ------------------------------------ */
.npm-agg__grid {
  display: grid;
  grid-template-columns: repeat(var(--npm-acols, 2), minmax(0, 1fr));
  gap: 14px;
}
.npm-agg[data-npm-cols="1"] { --npm-acols: 1; }
.npm-agg[data-npm-cols="2"] { --npm-acols: 2; }
.npm-agg[data-npm-cols="3"] { --npm-acols: 3; }
.npm-agg__col {
  min-width: 0;
  background: var(--np-bg);
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  overflow: hidden;
}
.npm-agg__head {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  padding: 12px 14px;
  background: var(--np-bg-soft);
  border-bottom: 1px solid var(--np-line);
}
.npm-agg__badge {
  flex: 0 0 38px;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background-color: var(--npm-c1);
  background-image: linear-gradient(135deg, var(--npm-c1), var(--npm-c2));
  color: #fff;
  font-size: 17px;
  font-weight: 700;
  line-height: 1;
}
.npm-agg__meta { flex: 1 1 auto; min-width: 0; }
.npm-agg__name { display: block; font-size: 15px; color: var(--np-text); }
.npm-agg__desc {
  margin: 2px 0 0;
  font-size: 12px;
  color: var(--np-text-2);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.npm-agg__count { display: inline-block; margin-top: 3px; font-size: 11px; color: var(--np-muted); }
.npm-agg__more { flex: 0 0 auto; font-size: 12px; color: var(--np-primary); }
.npm-agg__more i { margin-left: 3px; font-style: normal; }
.npm-agg__list { list-style: none; margin: 0; padding: 6px 14px 10px; }
.npm-agg__list li {
  display: flex;
  align-items: baseline;
  gap: 8px;
  min-width: 0;
  padding: 5px 0;
  font-size: 13px;
  border-bottom: 1px dashed var(--np-line);
}
.npm-agg__list li:last-child { border-bottom: 0; }
.npm-agg__list a {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--np-text);
}
.npm-agg__list a:hover { color: var(--np-primary); }
.npm-agg__views { flex: 0 0 auto; font-size: 11px; color: var(--np-muted); }

/* 58.3 文章 Mini 榜：紧凑序号列表 ----------------------------------------- */
.npm-mini { list-style: none; margin: 0; padding: 0; }
.npm-mini__item {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
  padding: 8px 0;
  border-bottom: 1px dashed var(--np-line);
}
.npm-mini__item:last-child { border-bottom: 0; }
.npm-mini__index {
  flex: 0 0 24px;
  text-align: center;
  font-size: 12px;
  font-weight: 600;
  color: var(--np-muted);
  font-variant-numeric: tabular-nums;
}
.npm-mini__item.is-top .npm-mini__index { color: var(--np-primary); font-weight: 700; }
.npm-mini__title {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
  color: var(--np-text);
}
.npm-mini__title:hover { color: var(--np-primary); }
.npm-mini__meta { flex: 0 0 auto; font-size: 11px; color: var(--np-muted); font-variant-numeric: tabular-nums; }

/* 58.4 用户排行榜：金银铜名次 + 头像 + 发文数 ------------------------------ */
.npm-urank { list-style: none; margin: 0; padding: 0; }
.npm-urank__item {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
  padding: 7px 0;
  border-bottom: 1px dashed var(--np-line);
}
.npm-urank__item:last-child { border-bottom: 0; }
.npm-urank__rank {
  flex: 0 0 20px;
  width: 20px;
  height: 20px;
  display: grid;
  place-items: center;
  border-radius: 5px;
  font-size: 11px;
  font-weight: 700;
  background: var(--np-bg-soft);
  color: var(--np-text-2);
}
.npm-urank__item.gold .npm-urank__rank { background: #f5d76e; color: #4a3300; }
.npm-urank__item.silver .npm-urank__rank { background: #d7dce3; color: #333c48; }
.npm-urank__item.bronze .npm-urank__rank { background: #e3b58a; color: #4a2a10; }
.npm-urank__main { flex: 1 1 auto; min-width: 0; display: flex; align-items: center; gap: 8px; }
.npm-urank__avatar {
  flex: 0 0 30px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--np-bg-soft);
}
.npm-urank__avatar--ph {
  display: grid;
  place-items: center;
  background: var(--np-primary-soft);
  color: var(--np-primary);
  font-weight: 700;
}
.npm-urank__name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 600;
  color: var(--np-text);
}
.npm-urank__value { flex: 0 0 auto; font-size: 12px; color: var(--np-text-2); font-variant-numeric: tabular-nums; }
.npm-urank__value i { font-style: normal; font-size: 11px; color: var(--np-muted); }

/* 58.5 图文封面：叠加 / 左图右文 / 上图下文 ------------------------------- */
.npm-cover {
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  overflow: hidden;
  background: var(--np-bg-soft);
}
.npm-cover__inner { position: relative; display: flex; min-width: 0; }
.npm-cover__media {
  position: relative;
  flex: 1 1 auto;
  min-width: 0;
  background: linear-gradient(120deg, var(--np-bg-soft), var(--np-line));
}
.npm-cover--wide .npm-cover__media { aspect-ratio: 21 / 9; }
.npm-cover--video .npm-cover__media { aspect-ratio: 16 / 9; }
.npm-cover--square .npm-cover__media { aspect-ratio: 4 / 3; }
.npm-cover__img,
.npm-cover__video,
.npm-cover__ph { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: cover; }
.npm-cover__ph { background: linear-gradient(135deg, var(--np-primary-soft), var(--np-bg-soft)); }
.npm-cover__body { min-width: 0; }
.npm-cover__heading { display: block; font-size: 20px; line-height: 1.4; }
.npm-cover__desc { margin: 6px 0 0; font-size: 13px; opacity: .9; }
.npm-cover__btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 14px;
  padding: 7px 14px;
  border-radius: var(--np-radius-sm);
  background: var(--np-primary);
  color: var(--np-bg);
  font-size: 13px;
  font-weight: 600;
}
.npm-cover__btn:hover { filter: brightness(1.08); }
.npm-cover__btn i { font-style: normal; }
.npm-cover--blue .npm-cover__btn { background: #2f49c9; color: #fff; }
.npm-cover--green .npm-cover__btn { background: #0b7d61; color: #fff; }
.npm-cover--purple .npm-cover__btn { background: #6d3fd1; color: #fff; }

.npm-cover--overlay .npm-cover__body {
  position: absolute;
  inset: auto 0 0 0;
  padding: 30px 20px 18px;
  color: #fff;
  /* 实色底兜底 + 渐变叠加：白字始终压在深色上，明暗两套模式对比度都稳；
     信息条只占封面底部，上方图片照常可见。 */
  background-color: rgb(12, 17, 24);
  background-image: linear-gradient(180deg, rgba(12, 17, 24, .15) 0%, rgba(12, 17, 24, .95) 68%);
}
.npm-cover--side .npm-cover__media { flex: 0 0 50%; }
.npm-cover--side .npm-cover__body {
  flex: 1 1 50%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 20px;
  background: var(--np-bg);
  color: var(--np-text);
}
.npm-cover--stack .npm-cover__inner { flex-direction: column; }
.npm-cover--stack .npm-cover__body { padding: 16px 18px; background: var(--np-bg); color: var(--np-text); }

/* 58.6 图库宫格 ----------------------------------------------------------- */
.npm-gal__grid {
  display: grid;
  grid-template-columns: repeat(var(--npm-gcols, 3), minmax(0, 1fr));
  gap: var(--npm-gap, 8px);
}
.npm-gal[data-npm-cols="2"] { --npm-gcols: 2; }
.npm-gal[data-npm-cols="3"] { --npm-gcols: 3; }
.npm-gal[data-npm-cols="4"] { --npm-gcols: 4; }
.npm-gal[data-npm-cols="5"] { --npm-gcols: 5; }
.npm-gal__item {
  position: relative;
  margin: 0;
  min-width: 0;
  overflow: hidden;
  border-radius: var(--npm-radius, 8px);
  background: var(--np-bg-soft);
}
.npm-gal__link { display: block; }
.npm-gal__item img { display: block; width: 100%; aspect-ratio: 1 / 1; object-fit: cover; }
.npm-gal[data-npm-ratio="43"] .npm-gal__item img { aspect-ratio: 4 / 3; }
.npm-gal[data-npm-ratio="169"] .npm-gal__item img { aspect-ratio: 16 / 9; }
.npm-gal__cap {
  position: absolute;
  inset: auto 0 0 0;
  padding: 5px 8px;
  font-size: 11px;
  color: #fff;
  background: linear-gradient(180deg, rgba(8, 12, 20, 0), rgba(8, 12, 20, .78));
}

/* 58.7 视频与嵌入 --------------------------------------------------------- */
.npm-media__frame {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: var(--np-radius);
  overflow: hidden;
  background: #0d1219;
}
.npm-media[data-npm-ratio="43"] .npm-media__frame { aspect-ratio: 4 / 3; }
.npm-media[data-npm-ratio="1"] .npm-media__frame { aspect-ratio: 1 / 1; }
.npm-media[data-npm-ratio="219"] .npm-media__frame { aspect-ratio: 21 / 9; }
.npm-media__video,
.npm-media__embed { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; object-fit: cover; }
.npm-media__ph { position: absolute; inset: 0; display: grid; place-items: center; color: #fff; font-size: 34px; opacity: .72; }
.npm-media__cap { margin: 8px 0 0; font-size: 12px; color: var(--np-muted); }

/* 58.8 一句话 ------------------------------------------------------------- */
.npm-quote {
  position: relative;
  padding: 18px 20px 14px;
  border-radius: var(--np-radius);
  border: 1px solid var(--np-line);
  background: var(--np-bg-soft);
}
.npm-quote--card { background: linear-gradient(120deg, var(--np-primary-soft), var(--np-bg)); border-left: 3px solid var(--np-primary); }
.npm-quote--plain { padding: 4px 0; border: 0; background: transparent; }
.npm-quote--center { text-align: center; }
.npm-quote__mark { display: block; height: 30px; font: 44px/1 Georgia, serif; color: var(--np-primary); opacity: .55; }
.npm-quote__text { margin: 2px 0 10px; font-size: 16px; line-height: 1.7; color: var(--np-text); }
.npm-quote__text.is-swap { animation: npm-quote-swap .35s ease; }
@keyframes npm-quote-swap {
  from { opacity: .2; transform: translateY(4px); }
  to { opacity: 1; transform: none; }
}
.npm-quote__foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.npm-quote--center .npm-quote__foot { justify-content: center; }
.npm-quote__author { font-size: 12px; color: var(--np-muted); }
.npm-quote__refresh {
  padding: 3px 10px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius-sm);
  background: var(--np-bg);
  color: var(--np-primary);
  font-size: 12px;
  cursor: pointer;
}
.npm-quote__refresh:hover { border-color: var(--np-primary); }

/* 58.9 滚动友链：两份内容无缝循环 ----------------------------------------- */
.npm-partner { overflow: hidden; }
.npm-partner__track { display: flex; width: max-content; animation: npm-marquee var(--npm-speed, 28s) linear infinite; }
.npm-partner__group { display: flex; gap: 10px; list-style: none; margin: 0; padding: 0 10px 0 0; }
.npm-partner__item { flex: 0 0 auto; min-width: 0; }
.npm-partner__link { display: flex; align-items: center; gap: 8px; padding: 8px 12px; border-radius: var(--np-radius-sm); }
.npm-partner--card .npm-partner__link { background: var(--np-bg); border: 1px solid var(--np-line); }
.npm-partner__logo { flex: 0 0 28px; width: 28px; height: 28px; border-radius: 6px; object-fit: cover; }
.npm-partner__logo--txt { display: grid; place-items: center; background: var(--np-primary-soft); color: var(--np-primary); font-size: 13px; font-weight: 700; }
.npm-partner__name { font-size: 13px; color: var(--np-text); white-space: nowrap; }
.npm-partner--pause:hover .npm-partner__track { animation-play-state: paused; }
@keyframes npm-marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* 58.10 模块入场动画：默认关闭，JS 就绪后才隐藏初始态 ---------------------- */
body.np-fx-ready [data-np-anim] {
  opacity: 0;
  transition: opacity .5s ease, transform .55s cubic-bezier(.22, .61, .36, 1);
}
body.np-fx-ready [data-np-anim="up"] { transform: translateY(18px); }
body.np-fx-ready [data-np-anim="scale"] { transform: scale(.96); }
body.np-fx-ready [data-np-anim="left"] { transform: translateX(-18px); }
body.np-fx-ready [data-np-anim].is-in { opacity: 1; transform: none; }

/* 58.11 双端适配：按挂件自身宽度收列（不选屏幕宽度） ---------------------- */
@container (max-width: 620px) {
  html body .npm-agg .npm-agg__grid { grid-template-columns: minmax(0, 1fr); }
  html body .npm-gal .npm-gal__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  html body .npm-cover--side .npm-cover__inner { flex-direction: column; }
  html body .npm-cover--side .npm-cover__body { padding: 16px; }
  html body .npm-quote .npm-quote__text { font-size: 15px; }
}
@container (max-width: 360px) {
  html body .npm-gal .npm-gal__grid { grid-template-columns: minmax(0, 1fr); }
  html body .npm-agg .npm-agg__head { flex-wrap: wrap; }
  html body .npm-cover .npm-cover__heading { font-size: 17px; }
}
@media (max-width: 600px) {
  html body .npm-cover--side .npm-cover__inner { flex-direction: column; }
  html body .npm-cover .npm-cover__heading { font-size: 17px; }
  html body .npm-cover--overlay .npm-cover__body { padding: 22px 14px 14px; }
}
@media (prefers-reduced-motion: reduce) {
  body.np-fx-ready [data-np-anim] { opacity: 1 !important; transform: none !important; transition: none; }
  .npm-partner__track { animation: none; }
  .npm-quote__text.is-swap { animation: none; }
}


/* ==========================================================================
   第 59 章 · 1.8.72 主内容位置化 + 间距修复
   --------------------------------------------------------------------------
   把主题原本「硬编码在首页 / 归档页模板里」的默认博客文章循环，改成可拖放的
   「NP 文章列表」小工具（详见 inc/widgets-postlist.php）。新增「主内容」槽位
   （np-wa-{page}-main）承载它；同时修掉「主内容下面」紧贴正文、没有留白的问题。
   本文件其余样式与 1.8.71 完全一致，第 59 章为纯末尾追加。
   ========================================================================== */

/* 59.1 主内容槽位：与「主内容上面 / 下面」一样，和相邻内容留出 20px。
   空位置（没拖小工具）整块不存在，不占空间、不产生多余留白。 */
.np-wa--above { margin: 0 0 20px; }
.np-wa--main { margin: 20px 0; }
.np-wa--below { margin: 20px 0 20px; }
.np-wa--main > * + * { margin-top: 16px; }
.np-wa--main > .np-module,
.np-wa--main > .np-widget { margin-bottom: 0; }

/* ==========================================================================
   第 62 章 · 1.8.75 NP 分类聚合 → 子比「聚合模块」卡片风格重做
   --------------------------------------------------------------------------
   对齐用户给定截图（子比「聚合模块」）：白卡 + 浅灰底；每张卡顶部两栏——
   左封面图、右信息区（标题 / 描述 / 底部一行：文章数 + 蓝色「更多文章」胶囊）；
   文章列表改用「青绿空心圆点 + 黑色标题 + 灰色阅读数」。红底白字 🔥 热度角标
   贴封面右上角，无封面时降级为卡片右上角红药丸。彻底移除 1.8.74 的「首字母
   色块 + 品牌渐变带 + 毛玻璃药丸」风格。仅命中 .npm-agg* 类名，其余组件零回归；
   本文件其余样式与 1.8.74 完全一致，第 62 章为纯末尾追加（覆写 58.2/60/61）。
   ========================================================================== */

/* 62.1 整卡：白底、轻描边、大圆角、柔和阴影；悬浮轻浮。 */
.npm-agg__col {
	position: relative;
	background: #fff;
	border: 1px solid var(--np-line, #ececec);
	border-radius: 12px;
	overflow: hidden;
	box-shadow: 0 1px 3px rgba(17, 24, 39, .05);
	transition: box-shadow .2s ease, transform .2s ease;
}
.npm-agg__col:hover {
	transform: translateY(-2px);
	box-shadow: 0 8px 22px rgba(17, 24, 39, .12);
}

/* 62.2 顶部两栏：左封面（圆角小图）+ 右信息。 */
.npm-agg__top {
	display: flex;
	gap: 13px;
	padding: 13px;
	align-items: stretch;
}
.npm-agg__cover {
	position: relative;
	flex: 0 0 38%;
	align-self: flex-start;
	display: block;
	border-radius: 9px;
	overflow: hidden;
	aspect-ratio: 3 / 2;
	background: linear-gradient(135deg, var(--npm-c1, #2f49c9), var(--npm-c2, #6d3fd1));
}
.npm-agg__cover img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform .35s ease;
}
.npm-agg__col:hover .npm-agg__cover img { transform: scale(1.05); }

/* 62.3 红底白字 🔥 热度角标：封面右上角；无封面时降级为卡片右上角红药丸。 */
.npm-agg__hot {
	position: absolute;
	top: 7px;
	right: 7px;
	z-index: 2;
	display: inline-flex;
	align-items: center;
	gap: 3px;
	padding: 2px 9px;
	border-radius: 999px;
	background: rgba(238, 58, 53, .94);
	color: #fff;
	font-size: 12px;
	font-weight: 700;
	line-height: 1.6;
	white-space: nowrap;
	box-shadow: 0 2px 6px rgba(0, 0, 0, .22);
}
.npm-agg__hot--inline {
	position: absolute;
	top: 12px;
	right: 12px;
	z-index: 3;
}

/* 62.4 右侧信息区：标题 / 描述 / 底部一行（文章数 + 更多）。 */
.npm-agg__info {
	flex: 1 1 auto;
	min-width: 0;
	display: flex;
	flex-direction: column;
}
.npm-agg__name {
	display: block;
	font-size: 16px;
	font-weight: 700;
	color: var(--np-text, #1f2329);
	line-height: 1.35;
}
.npm-agg__desc {
	margin: 5px 0 0;
	font-size: 12.5px;
	color: var(--np-text-2, #7a828f);
	line-height: 1.55;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}
.npm-agg__foot {
	margin-top: auto;
	padding-top: 10px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 8px;
}
.npm-agg__count {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	font-size: 12px;
	color: var(--np-muted, #9aa1ab);
}
.npm-agg__cico { width: 14px; height: 14px; fill: currentColor; flex: 0 0 auto; }
.npm-agg__foot a.npm-agg__more {
	flex: 0 0 auto;
	display: inline-flex;
	align-items: center;
	gap: 3px;
	padding: 5px 12px;
	border-radius: 999px;
	background: rgba(47, 127, 242, .10);
	color: #2f7ff2;
	font-size: 12px;
	font-weight: 600;
	transition: background .18s ease;
}
.npm-agg__foot a.npm-agg__more:hover { background: rgba(47, 127, 242, .20); }
.npm-agg__more i { font-style: normal; }

/* 62.5 文章列表：青绿空心圆点 + 黑色标题 + 灰色阅读数。 */
.npm-agg__list {
	list-style: none;
	margin: 0;
	padding: 4px 14px 14px;
	border-top: 1px solid var(--np-line, #f0f1f3);
}
.npm-agg__list li {
	display: flex;
	align-items: center;
	gap: 9px;
	min-width: 0;
	padding: 9px 0;
	font-size: 13px;
	border-bottom: 1px solid var(--np-line, #f2f3f5);
}
.npm-agg__list li:last-child { border-bottom: 0; }
.npm-agg__list li::before {
	content: "";
	flex: 0 0 auto;
	width: 7px;
	height: 7px;
	box-sizing: border-box;
	border: 2px solid #15a684;
	border-radius: 50%;
}
.npm-agg__list a {
	flex: 1 1 auto;
	min-width: 0;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	color: var(--np-text, #2b2f36);
}
.npm-agg__list a:hover { color: #15a684; }
.npm-agg__views {
	flex: 0 0 auto;
	font-size: 11px;
	color: var(--np-muted, #9aa1ab);
	white-space: nowrap;
}

/* 62.6 窄卡：封面变顶部通栏 banner，信息落到下方，避免封面被压太窄。 */
@container (max-width: 460px) {
	.npm-agg__top { flex-direction: column; gap: 10px; }
	.npm-agg__cover { flex: 0 0 auto; width: 100%; aspect-ratio: 16 / 7; }
}

/* ==========================================================================
   第 63 章 · 1.8.76 分类聚合跟随 9 套页面样式方案 + 观感优化
   --------------------------------------------------------------------------
   问题：1.8.75 第 62 章把卡片白底 / 12px 圆角 / 蓝色「更多文章」/ 青绿圆点
   全部写死，切换 cards / reading / newsprint / gallery / nebula / forum 等
   方案时聚合卡片「不换肤」，与整站气质脱节；第 58 章原有的 .npm-agg* 规则
   本来全都走 --np-* 令牌，是被第 62 章覆盖掉了。
   做法：纯末尾追加，不改动 1~62 章一个字节。
   1) 63.1 把第 62 章写死值改回 --np-* 令牌（9 套方案 + 暗色自动跟随）；
   2) 63.2 给 9 套方案写差异化点缀，统一用 html body.np-preset-* 提权，
      压过 wp_add_inline_style 输出的方案变量与第 42~49 章既有规则；
   3) 63.3 收窄手机通栏封面、给封面加一层轻渐隐，弱化纯色占位图的突兀感；
   4) 63.4 阅读数为 0 时前端不再渲染「阅读 0」（PHP 层改，数据零改动）。
   ========================================================================== */

/* 63.1 令牌化：把第 62 章写死值换成方案令牌 ------------------------------ */
.npm-agg {
	--npm-dot: #15a684;                         /* 列表空心圆点：默认子比青绿 */
	--npm-hot: rgba(238, 58, 53, .94);          /* 热度角标：语义红，9 套通用 */
	--npm-more-bg: var(--np-primary-soft, rgba(47, 127, 242, .10));
	--npm-more-fg: var(--np-primary, #2f7ff2);
	--npm-card-bg: var(--np-bg, #fff);
	--npm-card-line: var(--np-line, #ececec);
	--npm-card-radius: var(--np-radius, 12px);
	--npm-cover-radius: var(--np-radius-sm, 9px);
}
.npm-agg__col {
	background: var(--npm-card-bg);
	border-color: var(--npm-card-line);
	border-radius: var(--npm-card-radius);
	box-shadow: 0 1px 3px rgba(17, 24, 39, .05);
}
.npm-agg__col:hover { box-shadow: var(--np-shadow, 0 8px 22px rgba(17, 24, 39, .12)); }
.npm-agg__cover { border-radius: var(--npm-cover-radius); }
.npm-agg__cover::after {
	content: "";
	position: absolute;
	inset: 0;
	pointer-events: none;
	background: linear-gradient(180deg, rgba(0, 0, 0, 0) 58%, rgba(0, 0, 0, .14));
}
.npm-agg__hot { background: var(--npm-hot); }
.npm-agg__foot a.npm-agg__more {
	background: var(--npm-more-bg);
	color: var(--npm-more-fg);
}
.npm-agg__foot a.npm-agg__more:hover { background: var(--npm-more-bg); filter: brightness(.94); }
.npm-agg__list li::before { border-color: var(--npm-dot); }
.npm-agg__list a:hover { color: var(--npm-dot); }

/* 63.2 九套方案差异化点缀（html body 前缀提权，压过 inline CSS） ----------- */

/* 1) 资讯杂志 magazine（默认）：保持 1.8.75 的蓝色胶囊 + 青绿圆点 */
html body.np-preset-magazine .npm-agg {
	--npm-dot: #15a684;
	--npm-more-bg: rgba(47, 127, 242, .10);
	--npm-more-fg: #2f7ff2;
}

/* 2) 卡片社区 cards：紫渐变按钮 + 紫色圆点 */
html body.np-preset-cards .npm-agg {
	--npm-dot: #6d5ce7;
	--npm-more-bg: linear-gradient(135deg, #6d5ce7, #a78bfa);
	--npm-more-fg: #fff;
}
html body.np-preset-cards .npm-agg__name { font-weight: 800; letter-spacing: -.2px; }

/* 3) 极简阅读 reading：衬线标题 + 细横线，直角卡片由 --np-radius:0 自动跟随 */
html body.np-preset-reading .npm-agg {
	--npm-dot: #2f6b52;
	--npm-more-bg: var(--np-primary-soft, rgba(47, 106, 82, .10));
	--npm-more-fg: #2f6b52;
}
html body.np-preset-reading .npm-agg__name {
	font-family: var(--sp-serif, Georgia, serif); font-weight: 600; letter-spacing: .4px;
}
html body.np-preset-reading .npm-agg__name::before {
	content: ""; display: inline-block; width: 14px; height: 2px;
	margin-right: 8px; vertical-align: middle; background: #2f6b52;
}

/* 4) 导购商城 shop：橙渐变按钮 + 竖向渐变短条 */
html body.np-preset-shop .npm-agg {
	--npm-dot: #e0562a;
	--npm-more-bg: linear-gradient(135deg, #e0562a, #ff9a3c);
	--npm-more-fg: #fff;
}
html body.np-preset-shop .npm-agg__name { font-weight: 800; }
html body.np-preset-shop .npm-agg__name::before {
	content: ""; display: inline-block; width: 4px; height: 15px;
	margin-right: 8px; vertical-align: -2px; border-radius: 2px;
	background: linear-gradient(180deg, #e0562a, #ff9a3c);
}

/* 5) 报刊头条 newsprint：衬线标题 + 红竖条 */
html body.np-preset-newsprint .npm-agg {
	--npm-dot: var(--sp-red, #c0392b);
	--npm-more-bg: var(--np-primary-soft, rgba(192, 57, 43, .10));
	--npm-more-fg: var(--sp-red, #c0392b);
}
html body.np-preset-newsprint .npm-agg__name {
	font-family: var(--sp-serif, Georgia, serif); font-weight: 800;
}
html body.np-preset-newsprint .npm-agg__name::before {
	content: ""; display: inline-block; width: 4px; height: 15px;
	margin-right: 8px; vertical-align: -2px; background: var(--sp-red, #c0392b);
}

/* 6) 影像画廊 gallery：琥珀色 + 舒展字距 */
html body.np-preset-gallery .npm-agg {
	--npm-dot: var(--sp-amber, #d97706);
	--npm-more-fg: var(--sp-amber, #d97706);
}
html body.np-preset-gallery .npm-agg__name { letter-spacing: 1px; font-weight: 800; }

/* 7) 时光日志 timeline：等宽字体 + 蓝色圆点 */
html body.np-preset-timeline .npm-agg {
	--npm-dot: var(--sp-blue, #2f6b9e);
	--npm-more-fg: var(--sp-blue, #2f6b9e);
}
html body.np-preset-timeline .npm-agg__name {
	font-family: var(--sp-mono, monospace); letter-spacing: .3px;
}

/* 8) 星云科技 nebula：青紫渐变 + 等宽字体 */
html body.np-preset-nebula .npm-agg {
	--npm-dot: #0891b2;
	--npm-more-bg: linear-gradient(135deg, #4f46e5, #0891b2);
	--npm-more-fg: #fff;
}
html body.np-preset-nebula .npm-agg__name {
	font-family: var(--sp-mono, monospace); letter-spacing: .8px;
}

/* 9) 论坛社区 forum：蓝色方点标题，呼应分区表头语气 */
html body.np-preset-forum .npm-agg {
	--npm-dot: #3f5ee6;
	--npm-more-fg: #3f5ee6;
}
html body.np-preset-forum .npm-agg__name::before {
	content: ""; display: inline-block; width: 8px; height: 8px;
	margin-right: 8px; vertical-align: middle; border-radius: 3px; background: #3f5ee6;
}

/* 63.3 手机通栏封面：更扁 + 高度上限，弱化纯色占位图的大面积突兀感 ------ */
@container (max-width: 460px) {
	.npm-agg__cover {
		aspect-ratio: 16 / 6;
		max-height: 150px;
	}
}

/* 63.4 补齐 np-wx-* 小工具的令牌别名 ------------------------------------
   第 41 章的网址导航 / 链接 / 按钮 / 统计 / Flash 等小工具引用了
   --np-border / --np-card / --np-soft，但这三个变量从未在 :root 或方案里
   定义，永远落到写死的 fallback（#e4e7ec / #fff / #f6f8fa），于是 9 套
   方案与暗色模式下这批小工具「不换肤」。这里在 body 上把它们指向已有令牌：
   自定义属性里的 var() 在定义它的元素（body）上解析，正好能取到
   body.np-preset-* / body.np-dark 覆盖后的方案值。magazine 下新值与原
   fallback 基本一致，零视觉回归；--np-accent-soft 保持原样（VIP 标签语义色）。 */
body {
	--np-border: var(--np-line);
	--np-card: var(--np-bg);
	--np-soft: var(--np-bg-soft);
}

/* ==========================================================================
   第 64 章 · 1.8.77 分类聚合列表左右内收（圆点 / 文字 / 阅读数）
   --------------------------------------------------------------------------
   反馈：手机端文章列表的青绿空心圆点、标题、右侧阅读数过于贴卡片边缘，
   与上方标题 / 描述 / 更多文章按钮的留白不协调，希望整行「往里面一点」。
   做法：纯末尾追加，不改动 1~63 章一个字节；用 .npm-agg 前缀提权，把
   .npm-agg__list 左右内边距 14px → 20px，圆点 / 文字 / 阅读数 / li 分隔线
   随之整体内收，与上方 .npm-agg__top 的 13px 信息区留白更协调。
   桌面与手机、9 套方案与暗色模式一并生效，纯 CSS、数据零改动。
   ========================================================================== */
.npm-agg .npm-agg__list {
	padding-left: 20px;
	padding-right: 20px;
}

/* ==========================================================================
   第 65 章 · 1.8.78 NP 首屏英雄区（背景轮播 + 大搜索框 + 4 卡片）
   --------------------------------------------------------------------------
   参考 demo.zibll.com 首屏：深色背景大图轮播、居中大标题 / 副标题 / 胶囊大
   搜索框 / 热门词，下方 4 个白底圆角图标卡（PC 横排 4 个悬浮跨在 hero 底边，
   手机 2×2）。做成独立小工具（inc/widgets-hero.php），拖到「首页 - 顶部全宽」
   即可，主题不塞默认内容。
   · 纯末尾追加，不改动 1~64 章一个字节；类名统一 np-hero* 前缀，零回归。
   · 换肤全走 --np-* 令牌（卡片底 / 描边 / 圆角 / 文字 / 主色按钮 / 阴影），
     9 套方案与暗色模式自动跟随；背景恒为深色渐变或用户图，白字靠遮罩保清晰。
   · 通栏用 --np-vw（main.js 写成不含滚动条的 clientWidth），退回 100vw；
     避免 100vw 含滚动条宽度造成的横向溢出。
   ========================================================================== */
.np-hero {
	--np-hero-radius: var(--np-radius, 8px);
	--np-hero-card-bg: var(--np-bg, #fff);
	--np-hero-card-line: var(--np-line, #e6e9ee);
	--np-hero-shadow: var(--np-shadow, 0 1px 3px rgba(16,24,40,.06), 0 8px 24px rgba(16,24,40,.06));
	position: relative;
	grid-column: 1 / -1;                 /* 在 .np-wa--top 的 grid 里占满整行 */
	margin-bottom: 24px;                 /* 卡片已骑跨在 hero 底边内，仅留常规模块间距 */
	isolation: isolate;
}
/* 通栏：负 margin 拉到视口两边；--np-vw 由 JS 精确设置，无 JS 时用 100vw。 */
.np-hero--full {
	width: var(--np-vw, 100vw);
	max-width: var(--np-vw, 100vw);
	margin-left: calc(50% - var(--np-vw, 100vw) / 2);
	margin-right: calc(50% - var(--np-vw, 100vw) / 2);
}

/* --- 65.1 背景舞台：轮播层 + 遮罩 + 居中内容 ---------------------------- */
.np-hero__stage {
	position: relative;
	min-height: var(--np-hero-minh, 400px);
	border-radius: var(--np-hero-radius);
	overflow: hidden;
	background: #0b1e3a;                /* 图未加载时的底色 */
}
.np-hero--full .np-hero__stage { border-radius: 0; }

.np-hero__bgs,
.np-hero__bg,
.np-hero__veil {
	position: absolute;
	inset: 0;
}
.np-hero__bg {
	background-size: cover;
	background-position: center center;
	background-repeat: no-repeat;
	opacity: 0;
	transition: opacity .9s ease;
	will-change: opacity;
}
.np-hero__bg.is-active { opacity: 1; }

/* 深色渐变遮罩：让白字在任意浅色图上仍清晰；三档强度由 PHP 的 veil 字段控制。 */
.np-hero__veil {
	pointer-events: none;
	background: linear-gradient(180deg, rgba(6, 16, 34, .30) 0%, rgba(6, 16, 34, .55) 55%, rgba(6, 16, 34, .72) 100%);
}
.np-hero--veil-light .np-hero__veil {
	background: linear-gradient(180deg, rgba(6, 16, 34, .14) 0%, rgba(6, 16, 34, .34) 55%, rgba(6, 16, 34, .52) 100%);
}
.np-hero--veil-deep .np-hero__veil {
	background: linear-gradient(180deg, rgba(6, 16, 34, .48) 0%, rgba(6, 16, 34, .68) 55%, rgba(6, 16, 34, .84) 100%);
}

/* 居中内容 */
.np-hero__inner {
	position: relative;
	z-index: 2;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	text-align: center;
	gap: 0;
	min-height: var(--np-hero-minh, 400px);
	padding: 62px 24px 84px;
	box-sizing: border-box;
	color: #fff;
}
.np-hero__title {
	margin: 0;
	font-size: clamp(26px, 3.2vw, 40px);
	font-weight: 800;
	line-height: 1.3;
	letter-spacing: .5px;
	color: #fff;
	text-shadow: 0 2px 14px rgba(0, 0, 0, .35);
}
.np-hero__sub {
	margin: 12px 0 0;
	font-size: clamp(13px, 1.3vw, 15px);
	line-height: 1.6;
	color: rgba(255, 255, 255, .88);
	text-shadow: 0 1px 8px rgba(0, 0, 0, .3);
}

/* 胶囊大搜索框：半透明白底 + 蓝色按钮，宽度自适应、手机满宽 */
.np-hero__search {
	display: flex;
	align-items: center;
	gap: 8px;
	width: min(620px, 100%);
	margin: 26px 0 0;
	padding: 6px 6px 6px 20px;
	box-sizing: border-box;
	border-radius: 999px;
	background: rgba(255, 255, 255, .94);
	box-shadow: 0 8px 30px rgba(0, 0, 0, .22);
	backdrop-filter: blur(6px);
	transition: box-shadow .2s ease, background .2s ease;
}
.np-hero__search:focus-within {
	background: #fff;
	box-shadow: 0 10px 36px rgba(0, 0, 0, .30);
}
.np-hero__search-ico { flex: 0 0 auto; color: #8a94a3; }
.np-hero__search-input {
	flex: 1 1 auto;
	min-width: 0;
	border: 0;
	outline: 0;
	background: transparent;
	font-size: 15px;
	color: #1f2328;
	padding: 10px 4px;
}
.np-hero__search-input::placeholder { color: #98a1ad; }
.np-hero__search-btn {
	flex: 0 0 auto;
	border: 0;
	cursor: pointer;
	padding: 11px 26px;
	border-radius: 999px;
	background: var(--np-primary, #2271b1);
	color: #fff;
	font-size: 14px;
	font-weight: 700;
	transition: filter .18s ease, transform .18s ease;
}
.np-hero__search-btn:hover { filter: brightness(1.08); }
.np-hero__search-btn:active { transform: scale(.97); }

/* 热门词：半透明小胶囊 */
.np-hero__hots {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	align-items: center;
	gap: 8px;
	margin: 18px 0 0;
	max-width: 100%;
}
.np-hero__hots-label {
	font-size: 12px;
	color: rgba(255, 255, 255, .78);
	margin-right: 2px;
}
.np-hero__hot {
	padding: 3px 11px;
	border-radius: 999px;
	background: rgba(255, 255, 255, .16);
	border: 1px solid rgba(255, 255, 255, .22);
	color: rgba(255, 255, 255, .95);
	font-size: 12px;
	line-height: 1.5;
	text-decoration: none;
	transition: background .18s ease, border-color .18s ease;
}
.np-hero__hot:hover {
	background: rgba(255, 255, 255, .30);
	border-color: rgba(255, 255, 255, .45);
}

/* 左右箭头 + 指示点 */
.np-hero__nav {
	position: absolute;
	top: 46%;
	z-index: 3;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 38px;
	height: 38px;
	border: 1px solid rgba(255, 255, 255, .28);
	border-radius: 50%;
	background: rgba(0, 0, 0, .26);
	color: #fff;
	cursor: pointer;
	opacity: .62;
	transition: opacity .18s ease, background .18s ease, transform .18s ease;
}
.np-hero__nav:hover { opacity: 1; background: rgba(0, 0, 0, .46); }
.np-hero__nav--prev { left: 18px; }
.np-hero__nav--next { right: 18px; }
.np-hero__nav--prev:active { transform: translateX(-2px); }
.np-hero__nav--next:active { transform: translateX(2px); }

/* 指示点跟在内容流里（热门词下方、悬浮卡片上方），任何视口高度都不被遮挡。 */
.np-hero__dots {
	position: relative;
	z-index: 2;
	display: flex;
	justify-content: center;
	gap: 8px;
	margin: 20px 0 0;
}
.np-hero__dot {
	width: 8px;
	height: 8px;
	padding: 0;
	border: 0;
	border-radius: 999px;
	background: rgba(255, 255, 255, .42);
	cursor: pointer;
	transition: width .25s ease, background .25s ease;
}
.np-hero__dot.is-active { width: 22px; background: #fff; }

/* --- 65.2 4 个快捷入口卡片：PC 横排悬浮跨 hero 底边 ---------------------- */
.np-hero__cards {
	position: relative;
	z-index: 4;
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 14px;
	width: min(calc(var(--np-vw, 1200px) - 40px), 1180px);
	margin: 0 auto;
	padding: 0 20px;
	box-sizing: border-box;
	/* 卡片作为舞台（overflow:hidden）的兄弟节点，用负 margin 上提，
	   让上半部骑在深色舞台底边、下半部压到下方白底上，且不会被裁切。 */
	margin-top: -44px;
}
.np-hero--full .np-hero__cards { width: min(calc(var(--np-vw, 1200px) - 40px), 1180px); }

.np-hero__card {
	display: flex;
	align-items: center;
	gap: 12px;
	min-width: 0;
	padding: 15px 16px;
	border: 1px solid var(--np-hero-card-line);
	border-radius: var(--np-hero-radius);
	background: var(--np-hero-card-bg);
	box-shadow: var(--np-hero-shadow);
	color: var(--np-text, #1f2328);
	text-decoration: none;
	transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
a.np-hero__card:hover {
	transform: translateY(-3px);
	box-shadow: 0 12px 30px rgba(16, 24, 40, .14);
	border-color: var(--np-primary, #2271b1);
}
.np-hero__ic {
	flex: 0 0 auto;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 46px;
	height: 46px;
	border-radius: 14px;
	background: var(--np-hero-ic, #2271b1);
	color: #fff;
	overflow: hidden;
}
.np-hero__ic svg { display: block; }
.np-hero__ic img { width: 100%; height: 100%; object-fit: cover; }
.np-hero__ic-text { font-size: 20px; font-weight: 700; }
.np-hero__card-txt { display: flex; flex-direction: column; min-width: 0; gap: 3px; }
.np-hero__card-title {
	display: flex;
	align-items: center;
	gap: 6px;
	min-width: 0;
	font-size: 14px;
	font-weight: 700;
	line-height: 1.4;
	color: var(--np-text, #1f2328);
}
/* 标题文字可省略，角标 flex-shrink:0 永不被裁（窄卡手机上尤其重要）。 */
.np-hero__card-name {
	flex: 1 1 auto;
	min-width: 0;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}
.np-hero__badge {
	flex: 0 0 auto;
	padding: 1px 6px;
	border-radius: 5px;
	background: var(--np-hero-ic, #2271b1);
	color: #fff;
	font-size: 10px;
	font-style: normal;
	font-weight: 700;
	line-height: 1.5;
	white-space: nowrap;
}
.np-hero__card-desc {
	font-size: 12px;
	color: var(--np-muted, #7a838f);
	line-height: 1.45;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

/* --- 65.3 响应式：平板 2 列 / 手机 2×2 / 窄屏内收 ----------------------- */
@media (max-width: 900px) {
	.np-hero__stage,
	.np-hero__inner { min-height: var(--np-hero-minh, 380px); }
	.np-hero__cards { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: -84px; }
}
@media (max-width: 720px) {
	.np-hero__inner { padding: 46px 18px 70px; }
	.np-hero__title { font-size: 24px; }
	.np-hero__sub { font-size: 13px; }
	.np-hero__search { margin-top: 20px; padding-left: 16px; }
	.np-hero__search-btn { padding: 10px 18px; }
	/* 手机端隐藏两侧箭头：它们会压住整行铺开的热门词；切换用触摸滑动 + 指示点。 */
	.np-hero__nav { display: none; }
	.np-hero__hots { padding: 0 6px; }
}
@media (max-width: 480px) {
	.np-hero__stage,
	.np-hero__inner { min-height: var(--np-hero-minh, 360px); }
	.np-hero__inner { padding: 40px 14px 62px; }
	.np-hero__title { font-size: 21px; }
	.np-hero__search-input { font-size: 14px; }
	.np-hero__search-btn { padding: 10px 15px; font-size: 13px; }
	.np-hero__hots { gap: 6px; }
	.np-hero__hot { padding: 3px 9px; font-size: 11px; }
	.np-hero__cards { gap: 10px; padding: 0 14px; margin-top: -40px; }
	.np-hero__card { padding: 12px 10px; gap: 8px; }
	.np-hero__ic { width: 38px; height: 38px; border-radius: 11px; }
	.np-hero__ic svg { width: 18px; height: 18px; }
	.np-hero__card-title { font-size: 13px; gap: 4px; }
	/* 手机 2 列窄卡：角标浮到左上图标的右上角，标题独占整行、完整不省略。 */
	.np-hero__card { position: relative; }
	.np-hero__badge {
		position: absolute;
		top: 4px;
		left: 30px;                 /* 贴图标右上角，不越过 padding 进入文字区 */
		padding: 0 3px;
		font-size: 8px;
		line-height: 1.5;
		border-radius: 3px;
		box-shadow: 0 0 0 1.5px var(--np-hero-card-bg, #fff);
	}
	.np-hero__card-name { flex: 1 1 auto; }
	.np-hero__card-desc { font-size: 11px; }
}

/* 尊重减少动态效果偏好：关闭过渡与自动轮播（JS 也会跳过）。 */
@media (prefers-reduced-motion: reduce) {
	.np-hero__bg,
	.np-hero__card,
	.np-hero__dot { transition: none; }
}

/* ==========================================================================
   第 66 章 1.8.80 登录页品牌区独立设置（纯末尾追加，不改 1~65 章）
   品牌区 HTML 由 inc/auth-brand.php 生成，沿用原有 .np-auth__* 类名；
   这里只补上「Logo + 站点标题」同时出现时的间距与文字样式。
   ========================================================================== */
.np-auth__logo { gap: 10px; }
.np-auth__site-title { font-size: 20px; line-height: 1.35; }

/* ==========================================================================
   第 68 章 · 1.8.83 首屏顶栏衔接（弄齐 / 沉浸，参考子比）
   --------------------------------------------------------------------------
   问题：NP 首屏英雄区在「首页 - 顶部全宽」时，.np-main 的 24px 上内边距在
   白色 .np-header 与深蓝 hero 之间撑出一条白缝，形成「白导航 + 白缝 +
   深蓝块」断层。用户要「弄齐」，或「背景图显示到顶部、跟子比一样」。
   作用域由 inc/widgets-hero.php 的 body_class 精确限定：只有首页且顶部全宽
   区第一个小工具是 NP 首屏英雄区时，body 才带 np-hero-flush /
   np-hero-immersive；其它页面、没放英雄区、英雄区被可见性条件隐藏时一律
   零变化（main.js 另做一次兜底撤类）。
   · 纯末尾追加，不改 1~67 章一个字节；换肤走 --np-* 令牌，暗色自动跟随。
   · 沉浸态 header 脱离文档流、透明浮在 hero 背景上，滚过首屏由 main.js
     加 .is-solid 变实色，并与已有「上滑隐藏 / 下滑显示」协同。
   ========================================================================== */

/* 68.1 「弄齐」：消掉白缝，让深蓝首屏紧贴白色导航 ----------------------- */
body.np-hero-flush .np-main { padding-top: 0; }
body.np-hero-flush .np-wa--top > .np-hero { margin-top: 0; }
body.np-hero-flush .np-wa--top { margin-bottom: 0; }

/* 68.2 「沉浸」：header 固定透明，hero 背景铺到视口最顶 ----------------- */
body.np-hero-immersive .np-main { padding-top: 0; }
body.np-hero-immersive .np-wa--top > .np-hero { margin-top: 0; }
/* 顺带收紧卡片区与下方模块之间的白档（用户截图下方橙圈处）。 */
body.np-hero-immersive .np-wa--top { margin-bottom: 0; }

body.np-hero-immersive .np-header,
body.np-hero-immersive .np-header.is-sticky,
body.np-hero-immersive .np-header.np-header--autohide,
body.np-hero-immersive .np-header.is-sticky.np-header--autohide {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 60;
  background: transparent;
  border-bottom-color: transparent;
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  transition: transform 0.28s cubic-bezier(0.32, 0.72, 0, 1),
              background-color 0.22s ease,
              box-shadow 0.22s ease;
  will-change: transform, background-color;
}
/* 登录态 WordPress 工具条（电脑 32px / 手机 46px）不盖住透明导航。
   选择器需与 68.2 的主规则同权重以上，否则 top:0 会把它压掉。 */
body.np-hero-immersive.admin-bar .np-header,
body.np-hero-immersive.admin-bar .np-header.is-sticky,
body.np-hero-immersive.admin-bar .np-header.np-header--autohide,
body.np-hero-immersive.admin-bar .np-header.is-sticky.np-header--autohide { top: 32px; }
@media (max-width: 782px) {
  body.np-hero-immersive.admin-bar .np-header,
  body.np-hero-immersive.admin-bar .np-header.is-sticky,
  body.np-hero-immersive.admin-bar .np-header.np-header--autohide,
  body.np-hero-immersive.admin-bar .np-header.is-sticky.np-header--autohide { top: 46px; }
}

/* 首屏内容下移，避开浮在上面的导航（原 padding-top 62px 之上加一个 header 高） */
body.np-hero-immersive .np-hero__inner {
  padding-top: calc(var(--np-header-h, 64px) + 42px);
}

/* 68.3 透明态反白：文字 / 图标 / 描边在深色背景上可读 ----------------- */
body.np-hero-immersive .np-header:not(.is-solid) {
  color: #fff;
  --np-line: rgba(255, 255, 255, 0.30);
  --np-muted: rgba(255, 255, 255, 0.80);
}
body.np-hero-immersive .np-header:not(.is-solid) .np-brand,
body.np-hero-immersive .np-header:not(.is-solid) .np-brand *,
body.np-hero-immersive .np-header:not(.is-solid) .np-menu-toggle,
body.np-hero-immersive .np-header:not(.is-solid) .np-search-toggle,
body.np-hero-immersive .np-header:not(.is-solid) .np-user-toggle,
body.np-hero-immersive .np-header:not(.is-solid) .np-cart-toggle,
body.np-hero-immersive .np-header:not(.is-solid) .np-dark-toggle,
body.np-hero-immersive .np-header:not(.is-solid) .np-translate-toggle,
body.np-hero-immersive .np-header:not(.is-solid) .np-header__actions a,
body.np-hero-immersive .np-header:not(.is-solid) .np-header__actions button {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.34);
}
/* 手机端方形汉堡 / 搜索按钮：白底换成半透明玻璃，避免一块刺眼白 */
body.np-hero-immersive .np-header:not(.is-solid) .np-menu-toggle,
body.np-hero-immersive .np-header:not(.is-solid) .np-search-toggle,
body.np-hero-immersive .np-header:not(.is-solid) .np-user-toggle {
  background: rgba(255, 255, 255, 0.14);
}
body.np-hero-immersive .np-header:not(.is-solid) .np-menu-toggle__bars i {
  background-color: #fff;
}
/* 桌面端顶层导航链接反白；下拉子菜单仍是自己的白底深色字，不受影响 */
@media (min-width: 961px) {
  body.np-hero-immersive .np-header:not(.is-solid) .np-nav__list > li > a {
    color: #fff;
  }
}

/* 68.4 滚过首屏：变回实色导航（与 .is-hidden 位移互不干扰） ------------
   注意：68.2 里带 .is-sticky.np-header--autohide 的选择器权重达 (0,4,1)，
   这里必须列出同等组合并额外加 .is-solid 才能盖过 transparent 背景，
   否则滚动后文字恢复了深色、背景却还是透明的（白字白底）。 */
body.np-hero-immersive .np-header.is-solid,
body.np-hero-immersive .np-header.is-sticky.is-solid,
body.np-hero-immersive .np-header.np-header--autohide.is-solid,
body.np-hero-immersive .np-header.is-sticky.np-header--autohide.is-solid {
  background: color-mix(in srgb, var(--np-bg) 92%, transparent);
  border-bottom-color: var(--np-line);
  box-shadow: 0 1px 12px rgba(16, 24, 40, 0.08);
  backdrop-filter: saturate(180%) blur(10px);
  -webkit-backdrop-filter: saturate(180%) blur(10px);
}
body.np-hero-immersive .np-header.is-solid .np-menu-toggle__bars i {
  background-color: currentColor;
}

/* 抽屉打开：白底抽屉浮起时导航恢复实色与深色字，避免白字白底。
   同样提权到 (0,5,1)，盖过 68.2 的 transparent。 */
body.np-hero-immersive.np-drawer-on .np-header,
body.np-hero-immersive.np-drawer-on .np-header.is-sticky,
body.np-hero-immersive.np-drawer-on .np-header.np-header--autohide,
body.np-hero-immersive.np-drawer-on .np-header.is-sticky.np-header--autohide {
  background: var(--np-bg);
  color: var(--np-text);
}
body.np-hero-immersive.np-drawer-on .np-header .np-brand,
body.np-hero-immersive.np-drawer-on .np-header .np-brand * {
  color: var(--np-text);
}

@media (prefers-reduced-motion: reduce) {
  body.np-hero-immersive .np-header,
  body.np-hero-immersive .np-header.is-sticky.np-header--autohide { transition: none; }
}

/* ==========================================================================
   第 69 章 1.8.84 电脑端顶部导航随滚轮收放
   —— 与第 3 章（手机端）、第 68 章（沉浸首屏）相互独立，1~68 章零改动。
   断点 960px 与 main.js 的 isMobile() 保持一致。
   ========================================================================== */

/* 69.1 电脑端：开了「电脑端自动收起」就无条件吸顶（没吸顶时 header 随文档
   一起滚出视口，translateY(-100%) 根本看不出来，与手机端同一处理）。 */
@media (min-width: 961px) {
  .np-header--autohide-desktop {
    position: sticky;
    top: 0;
    z-index: 60;
    background: color-mix(in srgb, var(--np-bg) 88%, transparent);
    backdrop-filter: saturate(180%) blur(10px);
    transition: transform 0.28s cubic-bezier(0.32, 0.72, 0, 1);
    will-change: transform;
  }
  .np-header--autohide-desktop.is-sticky {
    transition: transform 0.28s cubic-bezier(0.32, 0.72, 0, 1);
    will-change: transform;
  }
  .np-header--autohide-desktop.is-hidden {
    transform: translateY(-100%);
  }
  /* 抽屉打开时头部必须原位，不然关抽屉会看到它从上面掉下来。 */
  body.np-drawer-on .np-header--autohide-desktop {
    transform: none;
  }

  /* 沉浸首屏在第 68 章把 header 设成 position:fixed，电脑端也要能滑走。
     68.2 主规则权重 (0,2,1)，这里 (0,3,1) 更高且不受其 background 影响。 */
  body.np-hero-immersive .np-header.is-hidden {
    transform: translateY(-100%);
  }
  body.np-hero-immersive.np-drawer-on .np-header.is-hidden {
    transform: none;
  }
}

/* 69.2 手机端沉浸态：第 3 章的位移规则已够，这里补一条高权重兜底，
   确保第 68 章 fixed 的透明顶栏不会被 transform 过渡卡住。 */
@media (max-width: 960px) {
  body.np-hero-immersive .np-header.is-hidden { transform: translateY(-100%); }
  body.np-hero-immersive.np-drawer-on .np-header.is-hidden { transform: none; }
}

/* 69.3 尊重系统「减少动态效果」 */
@media (prefers-reduced-motion: reduce) {
  .np-header--autohide-desktop { transition: none; }
}

/* ==========================================================================
   第 70 章 · 1.8.85 商品分类导航 Mega（参考 demo.wpcom.cn/sage 的 product-nav）
   —— 纯末尾追加，1~69 章零改动；只在 .np-catmega 存在时生效。
   桌面：左侧标题栏 + 横排分类，悬停 / focus-within 展开铺满容器的商品面板；
   手机与窄侧栏：自动降级成单列分类 + 点击展开的内嵌卡片，绝不横向溢出。
   ========================================================================== */
.np-catmega {
  --npc-head-w: 208px;
  position: relative;
  container-type: inline-size;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
  overflow: visible;
}
.np-catmega__head {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 12px 16px;
  color: #fff;
  background: var(--np-primary);
  border-radius: calc(var(--np-radius) - 1px) calc(var(--np-radius) - 1px) 0 0;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.4;
}
.np-catmega[data-np-theme="dark"] .np-catmega__head { background: #1f2733; }
.np-catmega[data-np-theme="light"] .np-catmega__head {
  background: #f3f6fa;
  color: var(--np-text);
  border-bottom: 1px solid var(--np-line);
}
.np-catmega__head-ico { display: inline-flex; flex: none; }
.np-catmega__head-title { flex: 1; min-width: 0; }
.np-catmega__head-more {
  flex: none;
  color: inherit;
  font-size: 12px;
  font-weight: 500;
  text-decoration: none;
  opacity: .88;
}
.np-catmega__head-more:hover { opacity: 1; text-decoration: underline; }

.np-catmega__list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 148px), 1fr));
  gap: 4px 6px;
  margin: 0;
  padding: 10px;
  list-style: none;
}
/* 关键：item 保持 static，让下面 absolute 的 mega 面板以 .np-catmega 为
   包含块，从而铺满整行（Sage 那种效果）；窄屏降级时面板改 static，也不依赖它。
   item 用 flex-wrap：桌面 toggle 隐藏、link 占满一行；手机 toggle 显示时与
   link 同排，静态面板换行占满整行，箭头不会再单独掉到下一行。 */
.np-catmega__item { display: flex; flex-wrap: wrap; align-items: center; min-width: 0; }
.np-catmega__link {
  display: flex;
  flex: 1 1 auto;
  align-items: center;
  gap: 8px;
  min-width: 0;
  padding: 8px 9px;
  border-radius: 6px;
  color: var(--np-text);
  text-decoration: none;
  transition: background var(--np-transition), color var(--np-transition);
}
.np-catmega__link:hover,
.np-catmega__item.is-open .np-catmega__link,
.np-catmega__item:hover > .np-catmega__link { background: color-mix(in srgb, var(--np-primary) 9%, transparent); }
.np-catmega__ico {
  display: grid;
  place-items: center;
  flex: none;
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: var(--nps-cat-c, var(--np-primary));
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  line-height: 1;
}
.np-catmega__name {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 600;
}
.np-catmega__count {
  flex: none;
  padding: 1px 6px;
  border-radius: 10px;
  background: color-mix(in srgb, var(--np-muted) 14%, transparent);
  color: var(--np-muted);
  font-size: 11px;
  line-height: 1.5;
}
.np-catmega__toggle {
  display: none;
  flex: none;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 30px;
  padding: 0;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--np-muted);
  font-size: 19px;
  line-height: 1;
  cursor: pointer;
}
.np-catmega__toggle:hover { background: color-mix(in srgb, var(--np-primary) 12%, transparent); color: var(--np-primary); }
.np-catmega__item.is-open .np-catmega__toggle span { transform: rotate(90deg); }
.np-catmega__toggle span { display: inline-block; transition: transform var(--np-transition); }

/* 70.2 桌面 mega 面板：绝对定位铺满容器，悬停 / 键盘聚焦即展开 */
.np-catmega__panel {
  position: absolute;
  z-index: 40;
  left: 0;
  right: 0;
  top: 100%;
  margin-top: 4px;
  visibility: hidden;
  opacity: 0;
  transform: translateY(-6px);
  pointer-events: none;
  transition: opacity 180ms ease, transform 180ms ease, visibility 180ms;
  background: var(--np-bg);
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  box-shadow: 0 12px 32px rgba(16, 24, 40, .14);
}
.np-catmega__item:hover > .np-catmega__panel,
.np-catmega__item:focus-within > .np-catmega__panel,
.np-catmega__item.is-open > .np-catmega__panel {
  visibility: visible;
  opacity: 1;
  transform: none;
  pointer-events: auto;
}
.np-catmega__panel-in { padding: 16px 18px 18px; }
.np-catmega__panel-head {
  display: flex;
  align-items: baseline;
  gap: 10px;
  padding-bottom: 12px;
  margin-bottom: 12px;
  border-bottom: 1px solid var(--np-line);
}
.np-catmega__panel-title {
  color: var(--np-text);
  font-size: 16px;
  font-weight: 700;
  text-decoration: none;
}
.np-catmega__panel-title:hover { color: var(--np-primary); }
.np-catmega__panel-count { color: var(--np-muted); font-size: 12px; }
.np-catmega__panel-all {
  margin-left: auto;
  color: var(--np-primary);
  font-size: 12px;
  text-decoration: none;
  white-space: nowrap;
}
.np-catmega__panel-all:hover { text-decoration: underline; }
.np-catmega__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 8px;
  margin-bottom: 14px;
}
.np-catmega__chip {
  padding: 3px 11px;
  border: 1px solid var(--np-line);
  border-radius: 14px;
  color: var(--np-muted);
  font-size: 12px;
  text-decoration: none;
  transition: all var(--np-transition);
}
.np-catmega__chip:hover { border-color: var(--np-primary); color: var(--np-primary); }
.np-catmega__goods {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 128px), 1fr));
  gap: 14px 12px;
}
.np-catmega__good {
  display: block;
  min-width: 0;
  color: var(--np-text);
  text-decoration: none;
}
.np-catmega__good-media {
  display: grid;
  place-items: center;
  aspect-ratio: 1 / 1;
  margin-bottom: 7px;
  overflow: hidden;
  border: 1px solid var(--np-line);
  border-radius: 8px;
  background: color-mix(in srgb, var(--np-muted) 6%, transparent);
}
.np-catmega__good-media img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: transform var(--np-transition);
}
.np-catmega__good:hover .np-catmega__good-media img { transform: scale(1.06); }
.np-catmega__good-ph {
  color: var(--np-muted);
  font-size: 26px;
  font-weight: 700;
  opacity: .5;
}
.np-catmega__good-title {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  font-size: 12px;
  line-height: 1.5;
}
.np-catmega__good:hover .np-catmega__good-title { color: var(--np-primary); }
.np-catmega__good-price {
  display: block;
  margin-top: 3px;
  color: var(--np-accent);
  font-size: 13px;
  font-weight: 700;
}
.np-catmega__empty {
  padding: 14px 0 4px;
  color: var(--np-muted);
  font-size: 13px;
}

/* 70.3 手机 / 窄侧栏：桌面 hover 浮层改成点击展开的静态内嵌卡片。
   用容器查询按小工具自身宽度判断，放侧栏也不会撑破布局。 */
@container (max-width: 620px) {
  .np-catmega__head { padding: 10px 13px; }
  .np-catmega__list { grid-template-columns: 1fr; gap: 2px; padding: 8px; }
  .np-catmega__link { padding: 7px 8px; }
  .np-catmega__toggle { display: inline-flex; }
  .np-catmega__panel {
    position: static;
    flex: 1 1 100%;
    display: none;
    margin: 2px 0 8px;
    visibility: visible;
    opacity: 1;
    transform: none;
    box-shadow: none;
    background: color-mix(in srgb, var(--np-muted) 5%, transparent);
  }
  .np-catmega__item.is-open > .np-catmega__panel { display: block; }
  .np-catmega__panel-in { padding: 12px 13px 14px; }
  .np-catmega__goods { grid-template-columns: repeat(auto-fill, minmax(min(100%, 96px), 1fr)); gap: 10px 8px; }
}
/* 不支持容器查询的旧浏览器：用视口宽度兜底，避免手机上出现 hover 浮层。 */
@supports not (container-type: inline-size) {
  @media (max-width: 960px) {
    .np-catmega__list { grid-template-columns: 1fr; }
    .np-catmega__toggle { display: inline-flex; }
    .np-catmega__panel {
      position: static; flex: 1 1 100%; display: none; margin: 2px 0 8px;
      visibility: visible; opacity: 1; transform: none; box-shadow: none;
      background: color-mix(in srgb, var(--np-muted) 5%, transparent);
    }
    .np-catmega__item.is-open > .np-catmega__panel { display: block; }
    .np-catmega__goods { grid-template-columns: repeat(auto-fill, minmax(min(100%, 96px), 1fr)); }
  }
}
/* 70.4 尊重系统「减少动态效果」 */
@media (prefers-reduced-motion: reduce) {
  .np-catmega__panel,
  .np-catmega__toggle span,
  .np-catmega__good-media img { transition: none; }
}


/* ==========================================================================
   第 71 章 · 1.8.86 独立「NP 商品分类导航」小工具（参考 Sage product-nav）
   —— 纯末尾追加，1~70 章零改动；只在 .np-pnav 存在时生效，与第 70 章
   .np-catmega 使用不同的类名前缀，两个小工具并存、样式互不干扰。
   桌面：左侧固定宽度竖排分类栏 + 悬停 / 聚焦浮出到右侧的大商品面板；
   手机与窄侧栏：容器查询降级成单列分类 + 点击箭头展开的内嵌卡片。
   ========================================================================== */
.np-pnav {
  --np-pnav-side-w: 236px;
  --np-pnav-head-bg: var(--np-primary);
  --np-pnav-head-fg: #fff;
  --np-pnav-min-h: 340px;
  --np-pnav-cols: 4;
  position: relative;
  container-type: inline-size;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
}
.np-pnav[data-np-cols="2"] { --np-pnav-cols: 2; }
.np-pnav[data-np-cols="3"] { --np-pnav-cols: 3; }
.np-pnav[data-np-cols="5"] { --np-pnav-cols: 5; }
.np-pnav[data-np-theme="dark"] { --np-pnav-head-bg: #1f2733; }
.np-pnav[data-np-theme="light"] {
  --np-pnav-head-bg: #f3f6fa;
  --np-pnav-head-fg: var(--np-text);
}
.np-pnav__side { min-height: var(--np-pnav-min-h); }
.np-pnav__head {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 13px 16px;
  color: var(--np-pnav-head-fg);
  background: var(--np-pnav-head-bg);
  border-radius: calc(var(--np-radius) - 1px) calc(var(--np-radius) - 1px) 0 0;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.4;
}
.np-pnav[data-np-theme="light"] .np-pnav__head { border-bottom: 1px solid var(--np-line); }
.np-pnav__head-ico { display: inline-flex; flex: none; }
.np-pnav__head-title { flex: 1; min-width: 0; }
.np-pnav__head-more {
  flex: none;
  color: inherit;
  font-size: 12px;
  font-weight: 500;
  text-decoration: none;
  opacity: .88;
}
.np-pnav__head-more:hover { opacity: 1; text-decoration: underline; }

/* 71.2 左侧竖排分类栏 */
.np-pnav__list {
  display: flex;
  flex-direction: column;
  width: var(--np-pnav-side-w);
  margin: 0;
  padding: 8px;
  list-style: none;
}
/* 关键：item 保持 static，让下面 absolute 的面板以 .np-pnav（container-type
   造成 layout containment）为包含块，才能铺满分类栏右侧；窄屏面板改 static
   后是普通 flex 子项，同样不依赖 item 的定位。 */
.np-pnav__item {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  min-width: 0;
}
.np-pnav__link {
  display: flex;
  flex: 1 1 auto;
  align-items: center;
  gap: 8px;
  min-width: 0;
  padding: 9px 8px;
  border-radius: 6px;
  color: var(--np-text);
  text-decoration: none;
  transition: background var(--np-transition), color var(--np-transition);
}
.np-pnav__item.is-active > .np-pnav__link,
.np-pnav__link:hover {
  background: color-mix(in srgb, var(--np-primary) 9%, transparent);
  color: var(--np-primary);
}
.np-pnav__ico {
  display: grid;
  place-items: center;
  flex: none;
  width: 26px;
  height: 26px;
  border-radius: 7px;
  background: var(--np-pnav-c, var(--np-primary));
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
}
.np-pnav__name {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 600;
}
.np-pnav__count {
  flex: none;
  padding: 1px 6px;
  border-radius: 10px;
  background: color-mix(in srgb, var(--np-muted) 14%, transparent);
  color: var(--np-muted);
  font-size: 11px;
  line-height: 1.5;
}
.np-pnav__arrow {
  flex: none;
  font-size: 17px;
  line-height: 1;
  color: var(--np-muted);
  transition: transform var(--np-transition);
}
.np-pnav__item.is-active > .np-pnav__link .np-pnav__arrow { transform: translateX(2px); color: var(--np-primary); }
.np-pnav__toggle {
  display: none;
  flex: none;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 30px;
  padding: 0;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--np-muted);
  font-size: 19px;
  line-height: 1;
  cursor: pointer;
}
.np-pnav__toggle:hover { background: color-mix(in srgb, var(--np-primary) 12%, transparent); color: var(--np-primary); }
.np-pnav__toggle span { display: inline-block; transition: transform var(--np-transition); }
.np-pnav__item.is-active > .np-pnav__toggle span { transform: rotate(90deg); }

/* 71.3 桌面浮层：以 .np-pnav 为包含块，铺在分类栏右侧、与分类栏等高 */
.np-pnav__panel {
  position: absolute;
  z-index: 40;
  top: 0;
  bottom: 0;
  left: var(--np-pnav-side-w);
  right: 0;
  overflow: auto;
  visibility: hidden;
  opacity: 0;
  transform: translateX(-6px);
  pointer-events: none;
  transition: opacity 180ms ease, transform 180ms ease, visibility 180ms;
  background: var(--np-bg);
  border-left: 1px solid var(--np-line);
  box-shadow: 8px 12px 28px rgba(16, 24, 40, .10);
}
/* JS 接管后只认 .is-active，避免「默认激活项 + hover 项」两片浮层叠在一起。 */
.np-pnav__item.is-active > .np-pnav__panel {
  visibility: visible;
  opacity: 1;
  transform: none;
  pointer-events: auto;
}
/* 无 JS 时的桌面兜底：原生 hover / 键盘聚焦，并临时收起默认激活的那一片。 */
@container (min-width: 701px) {
  body:not(.np-pnav-js) .np-pnav__item:hover > .np-pnav__panel,
  body:not(.np-pnav-js) .np-pnav__item:focus-within > .np-pnav__panel {
    visibility: visible;
    opacity: 1;
    transform: none;
    pointer-events: auto;
  }
  body:not(.np-pnav-js) .np-pnav__list:has(.np-pnav__item:hover) .np-pnav__item.is-active:not(:hover) > .np-pnav__panel {
    visibility: hidden;
    opacity: 0;
    pointer-events: none;
  }
}
.np-pnav__panel-in { padding: 16px 18px 18px; }
.np-pnav__panel-head {
  display: flex;
  align-items: baseline;
  gap: 10px;
  padding-bottom: 12px;
  margin-bottom: 12px;
  border-bottom: 1px solid var(--np-line);
}
.np-pnav__panel-title { color: var(--np-text); font-size: 16px; font-weight: 700; text-decoration: none; }
.np-pnav__panel-title:hover { color: var(--np-primary); }
.np-pnav__panel-count { color: var(--np-muted); font-size: 12px; }
.np-pnav__panel-all { margin-left: auto; color: var(--np-primary); font-size: 12px; text-decoration: none; white-space: nowrap; }
.np-pnav__panel-all:hover { text-decoration: underline; }
.np-pnav__chips { display: flex; flex-wrap: wrap; gap: 6px 8px; margin-bottom: 14px; }
.np-pnav__chip {
  padding: 3px 11px;
  border: 1px solid var(--np-line);
  border-radius: 14px;
  color: var(--np-muted);
  font-size: 12px;
  text-decoration: none;
  transition: all var(--np-transition);
}
.np-pnav__chip:hover { border-color: var(--np-primary); color: var(--np-primary); }
/* 列数由 data-np-cols 转成 CSS 变量，严格按配置排布；窄容器在下面
   @container 里改回 auto-fill 自动收列，绝不横向溢出。 */
.np-pnav__goods {
  display: grid;
  grid-template-columns: repeat(var(--np-pnav-cols, 4), minmax(0, 1fr));
  gap: 14px 12px;
}
@container (min-width: 701px) and (max-width: 860px) {
  .np-pnav__goods { grid-template-columns: repeat(auto-fill, minmax(min(100%, 118px), 1fr)); }
}
.np-pnav__good { display: block; min-width: 0; color: var(--np-text); text-decoration: none; }
.np-pnav__good-media {
  display: grid;
  place-items: center;
  aspect-ratio: 1 / 1;
  margin-bottom: 7px;
  overflow: hidden;
  border: 1px solid var(--np-line);
  border-radius: 8px;
  background: color-mix(in srgb, var(--np-muted) 6%, transparent);
}
.np-pnav__good-media img { width: 100%; height: 100%; object-fit: contain; transition: transform var(--np-transition); }
.np-pnav__good:hover .np-pnav__good-media img { transform: scale(1.06); }
.np-pnav__good-ph { color: var(--np-muted); font-size: 26px; font-weight: 700; opacity: .5; }
.np-pnav__good-title {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  font-size: 12px;
  line-height: 1.5;
}
.np-pnav__good:hover .np-pnav__good-title { color: var(--np-primary); }
.np-pnav__good-price { display: block; margin-top: 3px; color: var(--np-accent); font-size: 13px; font-weight: 700; }
.np-pnav__empty { padding: 14px 0 4px; color: var(--np-muted); font-size: 13px; }

/* 71.4 手机 / 窄侧栏：桌面浮层改成点击展开的静态内嵌卡片，绝不横向溢出 */
@container (max-width: 700px) {
  .np-pnav__side { min-height: 0; }
  .np-pnav__list { width: auto; gap: 2px; padding: 8px; }
  .np-pnav__arrow { display: none; }
  .np-pnav__toggle { display: inline-flex; }
  .np-pnav__panel {
    position: static;
    flex: 1 1 100%;
    display: none;
    overflow: visible;
    margin: 2px 0 8px;
    visibility: visible;
    opacity: 1;
    transform: none;
    pointer-events: auto;
    border: 1px solid var(--np-line);
    border-radius: 8px;
    box-shadow: none;
    background: color-mix(in srgb, var(--np-muted) 5%, transparent);
  }
  .np-pnav__item.is-active > .np-pnav__panel { display: block; }
  .np-pnav__panel-in { padding: 12px 13px 14px; }
  .np-pnav__goods { grid-template-columns: repeat(auto-fill, minmax(min(100%, 96px), 1fr)); gap: 10px 8px; }
}
/* 不支持容器查询的旧浏览器：用视口宽度兜底 */
@supports not (container-type: inline-size) {
  @media (min-width: 961px) {
    body:not(.np-pnav-js) .np-pnav__item:hover > .np-pnav__panel,
    body:not(.np-pnav-js) .np-pnav__item:focus-within > .np-pnav__panel {
      visibility: visible;
      opacity: 1;
      transform: none;
      pointer-events: auto;
    }
  }
  @media (max-width: 960px) {
    .np-pnav__side { min-height: 0; }
    .np-pnav__list { width: auto; gap: 2px; padding: 8px; }
    .np-pnav__arrow { display: none; }
    .np-pnav__toggle { display: inline-flex; }
    .np-pnav__panel {
      position: static; flex: 1 1 100%; display: none;
      overflow: visible; margin: 2px 0 8px;
      visibility: visible; opacity: 1; transform: none; pointer-events: auto;
      border: 1px solid var(--np-line); border-radius: 8px; box-shadow: none;
      background: color-mix(in srgb, var(--np-muted) 5%, transparent);
    }
    .np-pnav__item.is-active > .np-pnav__panel { display: block; }
    .np-pnav__panel-in { padding: 12px 13px 14px; }
    .np-pnav__goods { grid-template-columns: repeat(auto-fill, minmax(min(100%, 96px), 1fr)); }
  }
}
/* 71.5 尊重系统「减少动态效果」；暗色模式由主题的 --np-* 变量自动适配 */
@media (prefers-reduced-motion: reduce) {
  .np-pnav__panel,
  .np-pnav__toggle span,
  .np-pnav__good-media img,
  .np-pnav__link,
  .np-pnav__arrow,
  .np-pnav__chip { transition: none; }
}


/* ==========================================================================
   第 72 章 · 1.8.87 线报风格（参考 BaoLog 0.4.3）
   —— 纯末尾追加，1~71 章零改动；使用全新前缀 .np-blt / .np-blt-page，
   与第 70 章 .np-catmega、第 71 章 .np-pnav 完全隔离。
   两个入口共用同一套样式：「线报首页」页面模板 = 整页窄白卡（居中标题 +
   导航 + 搜索 + 胶囊 Tab + 紧凑列表 + 分页）；「NP 线报列表」小工具 = 把
   紧凑列表单独拖到任意小工具区域。无 JS 时用 :target 兜底切换 Tab。
   ========================================================================== */

/* 72.1 页面模板：浅灰底上一张居中窄白卡 */
body.np-blt-page {
  padding: 0;
  background: #eef1f5;
  font-size: 14px;
}
body.np-blt-page.np-dark { background: #0d1014; }
.np-blt-page__wrap {
  width: min(100% - 28px, 800px);
  margin: 34px auto 40px;
  padding: 30px 34px 26px;
  border: 1px solid var(--np-line);
  border-radius: 10px;
  background: var(--np-bg);
  box-shadow: 0 12px 40px rgba(20, 30, 45, .10);
}
.np-blt-page__masthead { margin-bottom: 28px; text-align: center; }
.np-blt-page__name {
  margin: 0 0 6px;
  color: var(--np-text);
  font-size: 2em;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: 1px;
}
.np-blt-page__name a { color: inherit; }
.np-blt-page__name a:hover { color: var(--np-primary); }
.np-blt-page__tagline { margin: 0; color: var(--np-muted); font-size: 13px; }

/* 72.2 横排主导航 + 搜索（左导航 / 右搜索，手机端堆叠） */
.np-blt-page__bar { display: flex; align-items: center; justify-content: space-between; gap: 18px; }
.np-blt-page__menu { display: flex; flex-wrap: wrap; gap: 20px; margin: 0; padding: 0; list-style: none; }
.np-blt-page__menu > li > a {
  display: inline-block;
  padding: 4px 0;
  border-bottom: 2px solid transparent;
  color: var(--np-text);
  font-size: 14px;
  white-space: nowrap;
}
.np-blt-page__menu > li > a:hover,
.np-blt-page__menu > li.current-menu-item > a,
.np-blt-page__menu > li.current_page_item > a { border-bottom-color: var(--np-primary); color: var(--np-primary); }
.np-blt-page__search { flex: none; }
.np-blt-page__search .np-search-form { display: flex; align-items: stretch; }
.np-blt-page__search .np-search-form input[type="search"] {
  width: 190px;
  padding: 6px 10px;
  border: 1px solid var(--np-line);
  border-right: 0;
  border-radius: 4px 0 0 4px;
  background: var(--np-bg);
  color: var(--np-text);
  font-size: 13px;
  line-height: 1.6;
}
.np-blt-page__search .np-search-form input[type="search"]:focus { outline: none; border-color: var(--np-primary); }
.np-blt-page__search .np-search-form button,
.np-blt-page__search .np-search-form button.np-btn {
  flex: none;
  padding: 0 16px;
  border: 0;
  border-radius: 0 4px 4px 0;
  background: #343a40;
  color: #fff;
  font-size: 13px;
  cursor: pointer;
}
.np-blt-page__search .np-search-form button:hover { background: #1f2733; }
.np-blt-page__divider { height: 1px; margin: 18px 0 4px; border-bottom: 1px solid var(--np-line); }
.np-blt-page__main { padding-top: 6px; }
.np-blt-page__foot {
  display: flex; justify-content: center; flex-wrap: wrap; gap: 14px;
  margin-top: 26px; padding-top: 16px;
  border-top: 1px solid var(--np-line);
  color: var(--np-muted); font-size: 12px;
}
.np-blt-page__foot a { color: var(--np-muted); }
.np-blt-page__foot a:hover { color: var(--np-primary); }
/* wp_footer 钩子里的全站浮层在线报首页不出现，保持「一张白卡」的干净观感 */
body.np-blt-page .np-login-modal,
body.np-blt-page .np-buy-panel,
body.np-blt-page .np-fab,
body.np-blt-page .np-side-tools { display: none !important; }

/* 72.3 线报组件（页面模板与小工具共用） */
.np-blt {
  --np-blt-tab-bg: #eeeeee;
  --np-blt-tab-fg: #343a40;
  --np-blt-tab-on-bg: #343a40;
  --np-blt-tab-on-fg: #fff;
  --np-blt-link: var(--np-text);
  --np-blt-time: var(--np-muted);
  position: relative;
  container-type: inline-size;
  font-size: 14px;
}
.np-blt[data-np-theme="primary"] {
  --np-blt-tab-bg: color-mix(in srgb, var(--np-primary) 10%, transparent);
  --np-blt-tab-fg: var(--np-text);
  --np-blt-tab-on-bg: var(--np-primary);
  --np-blt-tab-on-fg: #fff;
}
.np-blt[data-np-theme="light"] {
  --np-blt-tab-bg: #f2f4f7;
  --np-blt-tab-fg: #5b6472;
  --np-blt-tab-on-bg: #d9dee6;
  --np-blt-tab-on-fg: #1f2328;
}

/* 72.4 胶囊筛选 Tab */
.np-blt__tabs { display: flex; flex-wrap: wrap; justify-content: center; gap: 0; margin: 6px 0 18px; }
.np-blt__tab {
  display: inline-block;
  padding: .4em 1.5em;
  border-radius: 10rem;
  background: var(--np-blt-tab-bg);
  color: var(--np-blt-tab-fg);
  font-size: .9em;
  line-height: 1.6;
  text-decoration: none;
  white-space: nowrap;
  transition: background 160ms ease, color 160ms ease;
}
.np-blt__tab + .np-blt__tab { margin-left: 1.5em; }
.np-blt__tab:hover { color: var(--np-blt-tab-on-bg); }
.np-blt__tab.is-active { background: var(--np-blt-tab-on-bg); color: var(--np-blt-tab-on-fg); }
.np-blt__tab:focus-visible { outline: 2px solid var(--np-primary); outline-offset: 2px; }

/* 72.5 面板显示：JS 接管后只认 .is-active */
.np-blt__panel { display: none; }
.np-blt__panel.is-active { display: block; }

/* 72.6 紧凑单行线报列表 */
.np-blt__list { margin: 0; padding: 0; list-style: none; }
.np-blt__row {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  min-height: 34px; padding: 4px 0;
}
.np-blt__subject { display: flex; align-items: center; gap: 6px; flex: 1 1 auto; min-width: 0; }
.np-blt__title {
  min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  color: var(--np-blt-link); font-size: .95em; font-weight: 400; text-decoration: none;
}
.np-blt__title:hover { color: var(--np-primary); }
.np-blt__row.is-sticky .np-blt__title { font-weight: 600; }
.np-blt__flag { flex: none; font-size: .9em; font-weight: 700; white-space: nowrap; }
.np-blt__flag--today { color: var(--np-accent); }
.np-blt__flag--sticky { color: var(--np-text); }
.np-blt__tag {
  display: inline-block; flex: none;
  padding: 1px 7px; border-radius: 10rem;
  color: #fff; font-size: 11px; font-weight: 400; line-height: 1.6;
  text-decoration: none; white-space: nowrap;
  transition: filter 160ms ease;
}
.np-blt__tag:hover { color: #fff; filter: brightness(1.1); }
.np-blt__tag--red { background: #ec1611; }
.np-blt__tag--orange { background: #ff8b3d; }
.np-blt__tag--green { background: #1aad19; }
.np-blt__tag--blue { background: #409eff; }
.np-blt__tag--purple { background: #7b6cf6; }
.np-blt__tag--slate { background: #909399; }
.np-blt__time {
  flex: none; margin-left: auto;
  font-family: Consolas, monaco, Consolas, "Courier New", monospace;
  font-size: 12px; color: var(--np-blt-time); white-space: nowrap;
}
.np-blt__empty { margin: 26px 0; color: var(--np-muted); font-size: 13px; text-align: center; }
.np-blt__more { display: inline-block; margin: 0 0 10px; color: var(--np-primary); font-size: 12px; }
.np-blt__more:hover { text-decoration: underline; }

/* 72.7 居中分页 */
.np-blt__pager { margin-top: 22px; }
.np-blt__pager-list { display: flex; justify-content: center; flex-wrap: wrap; gap: 2px; margin: 0; padding: 0; list-style: none; }
.np-blt__pager-link {
  display: inline-block; min-width: 28px; padding: 4px 8px;
  border-radius: 4px; color: #868e96; font-size: 13px; text-align: center; text-decoration: none;
}
.np-blt__pager-link:hover { background: color-mix(in srgb, var(--np-primary) 8%, transparent); color: var(--np-primary); }
.np-blt__pager-link.is-current { color: var(--np-text); font-weight: 700; }
.np-blt__pager-gap span { display: inline-block; padding: 4px 6px; color: var(--np-muted); }

/* 72.8 无 JS 兜底：hash :target 切面板，并让胶囊高亮跟随 */
.np-blt:not(.np-blt-js) .np-blt__panel:target { display: block; }
.np-blt:not(.np-blt-js) .np-blt__panels:has(.np-blt__panel:target) .np-blt__panel.is-active:not(:target) { display: none; }
.np-blt:not(.np-blt-js):has(.np-blt__panel:target) .np-blt__tab.is-active {
  background: var(--np-blt-tab-bg);
  color: var(--np-blt-tab-fg);
}
.np-blt:not(.np-blt-js):has(.np-blt__panel[data-np-blt-panel="new"]:target) .np-blt__tab[data-np-blt-tab="new"],
.np-blt:not(.np-blt-js):has(.np-blt__panel[data-np-blt-panel="day"]:target) .np-blt__tab[data-np-blt-tab="day"],
.np-blt:not(.np-blt-js):has(.np-blt__panel[data-np-blt-panel="week"]:target) .np-blt__tab[data-np-blt-tab="week"] {
  background: var(--np-blt-tab-on-bg);
  color: var(--np-blt-tab-on-fg);
}

/* 72.9 窄侧栏（容器查询）与手机端降级 */
@container (max-width: 430px) {
  .np-blt__tabs { justify-content: flex-start; }
  .np-blt__tab { padding: .35em 1em; }
  .np-blt__tab + .np-blt__tab { margin-left: .6em; }
  .np-blt__row { flex-direction: column; align-items: flex-start; gap: 2px; padding: 7px 0; }
  .np-blt__subject { flex-wrap: wrap; width: 100%; max-width: 100%; }
  .np-blt__title { max-width: 100%; }
  .np-blt__time { margin-left: 0; font-size: 11px; }
}
@media (max-width: 576px) {
  .np-blt-page__wrap {
    width: 100%; margin: 0; padding: 22px 16px 24px;
    border: 0; border-radius: 0; box-shadow: none;
  }
  .np-blt-page__bar { flex-direction: column; align-items: stretch; gap: 14px; }
  .np-blt-page__menu { justify-content: center; gap: 16px; }
  .np-blt-page__search .np-search-form input[type="search"] { flex: 1 1 auto; width: auto; }
  .np-blt__row { flex-direction: column; align-items: flex-start; gap: 2px; padding: 7px 0; }
  .np-blt__subject { flex-wrap: wrap; width: 100%; max-width: 100%; }
  .np-blt__title { max-width: 100%; }
  .np-blt__time { margin-left: 0; font-size: 11px; }
  .np-blt__tabs { justify-content: center; }
  .np-blt__tab { padding: .35em 1em; }
  .np-blt__tab + .np-blt__tab { margin-left: .6em; }
}

/* 72.10 暗色模式：反色胶囊、卡片阴影、搜索按钮 */
body.np-dark .np-blt {
  --np-blt-tab-bg: #262c33;
  --np-blt-tab-fg: #c9d0d9;
  --np-blt-tab-on-bg: #e8eaed;
  --np-blt-tab-on-fg: #14181d;
}
body.np-dark .np-blt[data-np-theme="primary"] {
  --np-blt-tab-bg: color-mix(in srgb, var(--np-primary) 16%, transparent);
  --np-blt-tab-fg: #d6e4f5;
  --np-blt-tab-on-bg: var(--np-primary);
  --np-blt-tab-on-fg: #fff;
}
body.np-dark .np-blt[data-np-theme="light"] {
  --np-blt-tab-bg: #2a313a;
  --np-blt-tab-fg: #b9c1cb;
  --np-blt-tab-on-bg: #4a5461;
  --np-blt-tab-on-fg: #fff;
}
body.np-dark .np-blt__flag--sticky { color: var(--np-text); }
body.np-dark .np-blt-page__wrap { box-shadow: 0 12px 40px rgba(0, 0, 0, .38); }
body.np-dark .np-blt-page__search .np-search-form button,
body.np-dark .np-blt-page__search .np-search-form button.np-btn { background: #3b444f; }
body.np-dark .np-blt-page__search .np-search-form button:hover { background: #4b5663; }
body.np-dark .np-blt__tag { filter: saturate(.92); }

/* 72.11 尊重「减少动态效果」 */
@media (prefers-reduced-motion: reduce) {
  .np-blt__tab,
  .np-blt__tag,
  .np-blt__title,
  .np-blt__pager-link { transition: none; }
}


/* 72.12 隔离主题 .np-widget li 的全局虚线 / padding
   —— 小工具被拖进侧栏卡片时，主题第 3919 行的 `.np-widget li` 会给每行加
   1px dashed 分隔并清掉 padding；线报风要求「无边框紧凑单行」，因此用更高
   特异性把页面模板与小工具两个入口的列表外观拉齐，1~71 章仍然零改动。 */
.np-widget .np-blt__list,
.np-blt .np-blt__list { margin: 0; padding: 0; list-style: none; }
.np-widget .np-blt__row,
.np-blt .np-blt__row { padding: 4px 0; border: 0; border-bottom: 0; }
@media (max-width: 576px) {
  .np-widget .np-blt__row,
  .np-blt .np-blt__row { padding: 7px 0; }
}
@container (max-width: 430px) {
  .np-widget .np-blt__row,
  .np-blt .np-blt__row { padding: 7px 0; }
}


/* ==========================================================================
   第 73 章 · 1.8.88 线报风格增强（导航主题化 / 列表居中紧凑 / 文章页复刻）
   —— 纯末尾追加，1~72 章零改动；全部使用 .np-blt-nav / .np-blt-article /
   [data-np-layout] 新前缀，与第 70~72 章互不干扰。
   73.1 线报首页与线报文章共用「主题默认导航」的横排视觉（圆角 hover 底色、
   当前项高亮、二级下拉），菜单数据仍读主题 primary 菜单；
   73.2 列表 compact 排版：整行居中，时间紧跟标题，行宽随标题长度自适应；
   73.3 线报文章页：复刻 BaoLog single.php 的面包屑 / 居中大标题与元信息 /
   带层次感正文 / 等宽返回 / 编号相关文章 / 上下篇 / 评论区。
   ========================================================================== */

/* 73.1 主题默认导航样式（复刻 .np-nav 的桌面规则，独立 class 避免抽屉 JS 搬移） */
.np-blt-page__nav--theme { flex: 1 1 auto; min-width: 0; }
.np-blt-nav__list {
  display: flex; align-items: center; flex-wrap: wrap; gap: 2px;
  margin: 0; padding: 0; list-style: none;
}
.np-blt-nav__list li { position: relative; }
.np-blt-nav__list a {
  display: block; padding: 8px 12px;
  border-radius: var(--np-radius-sm);
  font-size: 15px; font-weight: 500;
  color: var(--np-text-2); white-space: nowrap; text-decoration: none;
}
.np-blt-nav__list a:hover,
.np-blt-nav__list .current-menu-item > a,
.np-blt-nav__list .current-menu-ancestor > a,
.np-blt-nav__list .current_page_item > a {
  color: var(--np-primary); background: var(--np-primary-soft);
}
/* 二级下拉：与主题 .np-nav ul ul 同款 */
.np-blt-nav__list ul {
  display: none; position: absolute; z-index: 30; top: 100%; left: 0;
  min-width: 168px; margin: 0; padding: 6px; list-style: none;
  background: var(--np-bg); border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  box-shadow: var(--np-shadow, 0 8px 24px rgba(16, 24, 40, .12));
}
.np-blt-nav__list li:hover > ul { display: block; }
.np-blt-nav__list ul a { font-size: 14px; padding: 7px 10px; }
.np-blt-nav__list ul li { position: static; }
.np-blt-nav__list ul ul { position: static; min-width: 0; border: 0; box-shadow: none; padding-left: 10px; }

/* 73.2 compact 列表：整行居中、时间紧跟标题、按标题长度自适应 */
.np-blt[data-np-layout="compact"] .np-blt__row { justify-content: center; }
.np-blt[data-np-layout="compact"] .np-blt__subject {
  flex: 0 1 auto; min-width: 0; max-width: 100%;
}
.np-blt[data-np-layout="compact"] .np-blt__title { flex: 0 1 auto; max-width: 100%; }
.np-blt[data-np-layout="compact"] .np-blt__time { margin-left: 10px; }
/* 窄容器：纵向堆叠但仍整体居中（覆盖 72.9 的左对齐降级） */
@container (max-width: 430px) {
  .np-blt[data-np-layout="compact"] .np-blt__row { flex-direction: column; align-items: center; gap: 2px; }
  .np-blt[data-np-layout="compact"] .np-blt__subject {
    flex-wrap: wrap; justify-content: center; width: auto; max-width: 100%;
  }
  .np-blt[data-np-layout="compact"] .np-blt__title { max-width: 100%; }
  .np-blt[data-np-layout="compact"] .np-blt__time { margin-left: 0; }
}
@media (max-width: 576px) {
  .np-blt[data-np-layout="compact"] .np-blt__row { flex-direction: column; align-items: center; gap: 2px; }
  .np-blt[data-np-layout="compact"] .np-blt__subject {
    flex-wrap: wrap; justify-content: center; width: auto; max-width: 100%;
  }
  .np-blt[data-np-layout="compact"] .np-blt__title { max-width: 100%; }
  .np-blt[data-np-layout="compact"] .np-blt__time { margin-left: 0; }
  .np-blt-nav__list { justify-content: center; gap: 4px; }
  .np-blt-nav__list a { padding: 6px 10px; font-size: 14px; }
  /* 触屏没有 hover，子菜单静态展开 */
  .np-blt-page__nav--theme .np-blt-nav__list ul,
  .np-blt-page__nav--theme .np-blt-nav__list ul ul {
    display: block; position: static; min-width: 0;
    border: 0; box-shadow: none; padding: 0 0 0 12px; background: transparent;
  }
}

/* 73.3 线报文章页（BaoLog single.php 观感） */
.np-blt-article__crumb {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
  margin: 0 0 22px; padding: 8px 14px;
  border-radius: var(--np-radius);
  background: color-mix(in srgb, var(--np-muted) 8%, transparent);
  color: var(--np-muted); font-size: 13px;
}
.np-blt-article__crumb a { color: var(--np-muted); text-decoration: none; }
.np-blt-article__crumb a:hover { color: var(--np-primary); }
.np-blt-article__crumb-cur { color: var(--np-text); }
.np-blt-article__crumb-sep { opacity: .5; }

.np-blt-article__top { margin: 4px 0 22px; text-align: center; }
.np-blt-article__title {
  margin: 0 0 14px; color: var(--np-text);
  font-size: 1.65em; font-weight: 700; line-height: 1.45; word-break: break-word;
}
.np-blt-article__meta {
  display: flex; flex-wrap: wrap; justify-content: center; align-items: center;
  gap: 6px 14px; color: var(--np-muted); font-size: 12.5px;
}
.np-blt-article__meta-item { display: inline-flex; align-items: center; gap: 5px; }
.np-blt-article__meta a { color: var(--np-muted); text-decoration: none; }
.np-blt-article__meta a:hover { color: var(--np-primary); }
.np-blt-article__avatar { border-radius: 50%; }
.np-blt-article__divider { height: 1px; margin: 20px 0; background: var(--np-line); }

/* 正文：h2 灰底左竖线 / h3 底部短横线 / h4 书名号 / blockquote 蓝框 / 图片圆角阴影 */
.np-blt-article__content { color: var(--np-text); font-size: 1.05em; line-height: 1.9; }
.np-blt-article__content p { margin: 0 0 14px; }
.np-blt-article__content img,
.np-blt-article__content p > img {
  display: block; max-width: 92%; height: auto; margin: 20px auto;
  border-radius: 12px; box-shadow: 0 6px 22px rgba(20, 30, 45, .18);
}
.np-blt-article__content h1,
.np-blt-article__content h2,
.np-blt-article__content h3,
.np-blt-article__content h4,
.np-blt-article__content h5,
.np-blt-article__content h6 { margin: 22px 0 14px; color: var(--np-text); line-height: 1.6; }
.np-blt-article__content h2 {
  position: relative; margin: 20px 0 14px; padding: 7px 0 7px 16px;
  border: 0; border-radius: 4px;
  background: color-mix(in srgb, var(--np-muted) 9%, transparent);
  color: var(--np-primary); font-size: 1.15em; font-weight: 700;
}
.np-blt-article__content h2::before {
  content: ''; position: absolute; left: 4px; top: 12%; bottom: 12%;
  width: 4px; border-radius: 5px; background: var(--np-primary);
}
.np-blt-article__content h3 { position: relative; padding-bottom: 12px; font-size: 1.1em; }
.np-blt-article__content h3::after {
  content: ''; position: absolute; left: 0; bottom: 3px;
  width: 40px; height: 3px; border-radius: 5px; background: var(--np-primary);
}
.np-blt-article__content h4::before { content: '「'; color: var(--np-primary); font-weight: 600; }
.np-blt-article__content h4::after { content: '」'; color: var(--np-primary); font-weight: 600; }
.np-blt-article__content blockquote {
  margin: 0 0 16px; padding: 10px 16px;
  border-left: 5px solid #50bfff; border-radius: 0 6px 6px 0;
  background: color-mix(in srgb, #50bfff 9%, transparent); line-height: 1.8;
}
.np-blt-article__content blockquote p { margin: 0; }
.np-blt-article__content ul,
.np-blt-article__content ol { margin: 0 0 16px; padding-left: 1.8em; }
.np-blt-article__content a { color: var(--np-primary); }
.np-blt-article__pages { display: flex; flex-wrap: wrap; gap: 8px; margin: 18px 0; }
.np-blt-article__pages a {
  padding: 3px 10px; border: 1px solid var(--np-line); border-radius: 6px;
  color: var(--np-text-2); text-decoration: none;
}
.np-blt-article__pages a:hover { border-color: var(--np-primary); color: var(--np-primary); }

/* 标签 / 等宽返回 / 上下篇 */
.np-blt-article__tags { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: 24px 0 8px; }
.np-blt-article__tag {
  padding: 3px 11px; border: 1px solid var(--np-line); border-radius: 10rem;
  color: var(--np-muted); font-size: 12px; text-decoration: none;
}
.np-blt-article__tag:hover { border-color: var(--np-primary); color: var(--np-primary); }
.np-blt-article__back { margin: 22px 0 26px; text-align: center; }
.np-blt-article__back a {
  font-family: Consolas, monaco, "Courier New", monospace;
  color: #868e96; font-size: 13px; text-decoration: none;
}
.np-blt-article__back a:hover { color: var(--np-primary); }
.np-blt-article__postnav {
  display: flex; justify-content: space-between; gap: 16px;
  margin: 0 0 24px; padding: 14px 0;
  border-top: 1px solid var(--np-line); border-bottom: 1px solid var(--np-line);
}
.np-blt-article__postnav-item { display: flex; flex-direction: column; gap: 4px; min-width: 0; max-width: 48%; }
.np-blt-article__postnav-item--next { align-items: flex-end; text-align: right; }
.np-blt-article__postnav-item span { color: var(--np-muted); font-size: 12px; }
.np-blt-article__postnav-item a {
  max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  color: var(--np-text); font-size: 13px; text-decoration: none;
}
.np-blt-article__postnav-item a:hover { color: var(--np-primary); }

/* 相关文章：两列编号列表，橙色序号（复刻 BaoLog .related-list） */
.np-blt-article__related { margin: 0 0 28px; }
.np-blt-article__related-title { margin: 0 0 12px; text-align: center; color: var(--np-text); font-size: 15px; font-weight: 700; }
.np-blt-article__related-list {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 18px;
  margin: 0; padding: 0; list-style: none;
}
.np-blt-article__related-list li {
  display: flex; align-items: baseline; gap: 8px; min-width: 0;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  font-size: 13px; line-height: 2.2;
}
.np-blt-article__related-list li span {
  flex: none; width: 16px; text-align: right;
  color: #ff8b3d; font-family: Consolas, monaco, monospace;
}
.np-blt-article__related-list li a {
  overflow: hidden; text-overflow: ellipsis;
  color: var(--np-text-2); text-decoration: none;
}
.np-blt-article__related-list li a:hover { color: var(--np-primary); }

/* 评论区沿用主题 comments.php，只做窄白卡内的轻量适配 */
body.np-blt-article .np-comments { margin-top: 6px; }
body.np-blt-article .np-comments__title { font-size: 16px; }
body.np-blt-article .np-comment-list { padding-left: 0; list-style: none; }
body.np-blt-article .np-comments input[type="text"],
body.np-blt-article .np-comments input[type="email"],
body.np-blt-article .np-comments input[type="url"],
body.np-blt-article .np-comments textarea {
  box-sizing: border-box; max-width: 100%;
  border: 1px solid var(--np-line); border-radius: 6px;
  background: var(--np-bg); color: var(--np-text);
}

/* 73.4 暗色 / 窄屏 / 减少动效 */
body.np-dark .np-blt-article__back a { color: #9aa3ad; }
body.np-dark .np-blt-article__content img { box-shadow: 0 6px 22px rgba(0, 0, 0, .42); }
@media (max-width: 576px) {
  .np-blt-article__title { font-size: 1.4em; }
  .np-blt-article__related-list { grid-template-columns: 1fr; }
  .np-blt-article__postnav { flex-direction: column; }
  .np-blt-article__postnav-item,
  .np-blt-article__postnav-item--next { max-width: 100%; align-items: flex-start; text-align: left; }
}
@media (prefers-reduced-motion: reduce) {
  .np-blt-nav__list a,
  .np-blt-article__tag,
  .np-blt-article__back a { transition: none; }
}


/* ==========================================================================
   第 74 章 · 1.8.89 线报：主题原生头尾 / 960px 宽度 / 文章内按钮配色修复
   —— 纯末尾追加，1~73 章零改动。
   74.1 页面模板与文章页默认改用主题 get_header()/get_footer()（body 带
   .np-blt-embedded，不带 .np-blt-page，因此第 72 章的浅灰底 / 隐藏浮层等
   独立白卡强样式一律不触发，主题头部、页脚、浮层全部照常显示）；
   74.2 内容宽度用 --np-blt-w 变量下发，默认 960px 居中、两端对齐，可自定义；
   74.3 修复 1.8.88 第 73 章 .np-blt-article__content a{color:var(--np-primary)}
   把正文里 .np-btn 实心按钮的白字染成主色，导致「青底看不见字」的问题。
   ========================================================================== */

/* 74.1 主题原生头尾：中间内容承载区 */
.np-blt-embedded__main,
.np-blt-embedded__article {
  max-width: var(--np-blt-w, 960px);
  margin-inline: auto;
}
.np-blt-embedded__main { padding: 8px 0 28px; }
.np-blt-embedded__article {
  margin-block: 10px 40px;
  padding: 28px 32px 30px;
  border: 1px solid var(--np-line);
  border-radius: var(--np-radius);
  background: var(--np-bg);
  box-shadow: 0 10px 34px rgba(20, 30, 45, .07);
}
body.np-dark .np-blt-embedded__article { box-shadow: 0 10px 34px rgba(0, 0, 0, .34); }
/* 主题头部 / 页脚 / 搜索 / 登录浮层属于主题自身：embedded 模式 body 不带
   .np-blt-page，第 72 章的 display:none!important 不会命中，全部照常显示。 */

/* 74.2 内容宽度：容器自身带变量时按变量限宽并居中（0 = 不下发，跟随外层） */
.np-blt[data-np-width] {
  max-width: var(--np-blt-w, 960px);
  margin-inline: auto;
}
/* 960px 两端对齐：标题在左、更新时间在右，整行铺满，行宽不再随标题收缩 */
.np-blt[data-np-layout="split"] .np-blt__row { justify-content: space-between; }
.np-blt[data-np-layout="split"] .np-blt__subject { flex: 1 1 auto; min-width: 0; }
.np-blt[data-np-layout="split"] .np-blt__time { margin-left: auto; }

/* 74.3 修复：线报文章正文内的付费 / 会员 / 下载等 shortcode 按钮文字颜色。
   根因：1.8.88 第 73 章 .np-blt-article__content a{color:var(--np-primary)}
   特异性 (0,1,1) 高于通用 .np-btn{color:#fff}(0,1,0)，把实心主按钮的白字
   染成主色，与同为 --np-primary 的背景融为一体（青底看不见字）。
   这里用 (0,2,0) 恢复：实心按钮白字、ghost 描边按钮主色字；
   刻意保持在 (0,2,1) 以下，让 np-preset-* 皮肤自定义的按钮配色仍能覆盖。 */
.np-blt-article__content .np-btn,
.np-blt-article__content .np-btn:visited { color: #fff; }
.np-blt-article__content .np-btn--ghost,
.np-blt-article__content .np-btn--ghost:visited { color: var(--np-primary); }
.np-blt-article__content .np-btn:hover,
.np-blt-article__content .np-btn:focus-visible { color: #fff; }
.np-blt-article__content .np-btn--ghost:hover,
.np-blt-article__content .np-btn--ghost:focus-visible { color: var(--np-primary); }
/* 下载条、付费卡、会员卡里的按钮容器一并兜住（含 <button> 与 <a>） */
.np-blt-article__content .np-download__btn,
.np-blt-article__content .np-locked__actions .np-btn,
.np-blt-article__content .np-locked__actions .np-btn:visited { color: #fff; }
.np-blt-article__content .np-download__btn.np-btn--ghost,
.np-blt-article__content .np-locked__actions .np-btn--ghost,
.np-blt-article__content .np-locked__actions .np-btn--ghost:visited { color: var(--np-primary); }

/* 74.4 窄屏 / 手机：白卡留白收敛，宽度始终不横向溢出 */
@media (max-width: 576px) {
  .np-blt-embedded__article { padding: 20px 16px 24px; margin-block: 0 24px; border-radius: 0; border-left: 0; border-right: 0; }
  .np-blt-embedded__main { padding: 4px 0 18px; }
}
/* 74.5 尊重「减少动态效果」 */
@media (prefers-reduced-motion: reduce) {
  .np-blt-embedded__article { box-shadow: none; }
}

/* ==========================================================================
   第 75 章 · 1.8.90 线报列表：手机两行式（参考截图）/ 桌面 BaoLog 紧凑单行
   —— 纯末尾追加，1~74 章零改动；沿用 .np-blt 前缀，与 70/71/72/73/74 章隔离。
   75.1 窄侧栏容器（≤430px）：两行式，字号略收敛，Tab 保持 72.9 的紧凑靠左避免溢出。
   75.2 手机端（≤576px）：完整复刻参考截图 ——
        · Tab 恢复居中大胶囊（72.9 曾为窄屏缩小并靠左），沿用 72.3 深灰/浅灰配色；
        · 第一行：完整标题（取消 ellipsis 截断，允许换行）+ 彩色全圆角大胶囊标签；
        · 第二行：灰色大字号等宽时间，居左与标题对齐；
        · 条目之间留大段空白、无分割线、隐藏置顶/今日标记，整体成「阅读列表」；
        · 两个入口（线报首页页面模板 + NP 线报列表小工具）共用同一套 .np-blt，
          因此自动同时生效；compact 的居中降级与 72.12 的小行距一并被覆盖。
   75.3 桌面端（>576px）刻意保持 1.8.89 的 960px 两端对齐 + BaoLog 紧凑单行
        （标题左 / 时间右 / 彩色小标签 / 置顶标记），只补一个极轻的行 hover 反馈；
        宽屏不套两行式，避免信息密度骤降。
   75.4 新增 layout=stack（两行式）作为可选排版，供桌面 / 窄侧栏显式选用，
        旧 split / compact 完全保留，不做取舍。
   说明：以下统一用 .np-blt .np-blt__list 前缀把特异性提到 (0,3,0)，
        以覆盖第 73 章 compact 的 (0,3,0) 窄屏降级与第 72.12 章的 (0,2,0) 行距。
   ========================================================================== */

/* 75.1 窄侧栏容器：两行式（字号略小，避免在 300px 侧栏里过大） */
@container (max-width: 430px) {
  .np-blt .np-blt__list .np-blt__row {
    flex-direction: column; align-items: flex-start; justify-content: flex-start;
    gap: 6px; min-height: 0; padding: 0; margin: 0 0 22px;
    border: 0; border-bottom: 0;
  }
  .np-blt .np-blt__list .np-blt__subject {
    flex-wrap: wrap; align-items: center; gap: 6px; width: 100%; max-width: 100%;
  }
  .np-blt .np-blt__list .np-blt__title {
    max-width: 100%; font-size: 15px; font-weight: 500;
    white-space: normal; overflow: visible; text-overflow: clip;
  }
  .np-blt .np-blt__list .np-blt__tag { padding: 3px 10px; font-size: 12px; line-height: 1.5; }
  .np-blt .np-blt__list .np-blt__time { margin-left: 0; font-size: 14px; color: #9aa1a9; }
  .np-blt .np-blt__list .np-blt__flag { display: none; }
}

/* 75.2 手机端：参考截图两行式（放在 75.1 之后，手机上以本组为准） */
@media (max-width: 576px) {
  /* Tab：居中大胶囊，激活深灰白字 / 未激活浅灰深字沿用 72.3 变量 */
  .np-blt .np-blt__tabs { justify-content: center; gap: 8px; margin: 4px 0 30px; }
  .np-blt .np-blt__tab { padding: .6em 1.05em; font-size: 15px; line-height: 1.5; }
  .np-blt .np-blt__tab + .np-blt__tab { margin-left: 0; }

  .np-blt .np-blt__list .np-blt__row {
    flex-direction: column; align-items: flex-start; justify-content: flex-start;
    gap: 8px; min-height: 0; padding: 0; margin: 0 0 32px;
    border: 0; border-bottom: 0;
  }
  /* 标题与标签走同一文本流：长标题自然换行后，标签紧跟在末行文字后面，
     而不是被 flex 挤成独立一整行（更贴近参考截图的「标题+标签紧连」观感）。 */
  .np-blt .np-blt__list .np-blt__subject {
    display: block; width: 100%; max-width: 100%;
  }
  .np-blt .np-blt__list .np-blt__title {
    display: inline; max-width: 100%; font-size: 17px; font-weight: 500;
    white-space: normal; overflow: visible; text-overflow: clip;
  }
  .np-blt .np-blt__list .np-blt__tag {
    display: inline-block; margin: 0 0 0 8px; vertical-align: 2px;
    padding: 4px 12px; font-size: 13px; line-height: 1.5;
  }
  .np-blt .np-blt__list .np-blt__time { margin-left: 0; font-size: 16px; color: #9aa1a9; }
  .np-blt .np-blt__list .np-blt__flag { display: none; }
  /* 手机端标签配色贴近参考截图：橙 / 红 / 玫红 / 绿 / 蓝，去掉灰紫 */
  .np-blt .np-blt__list .np-blt__tag--orange { background: #ff9f2e; }
  .np-blt .np-blt__list .np-blt__tag--red { background: #e8342a; }
  .np-blt .np-blt__list .np-blt__tag--green { background: #2ead2e; }
  .np-blt .np-blt__list .np-blt__tag--blue { background: #409eff; }
  .np-blt .np-blt__list .np-blt__tag--purple { background: #f0334e; }
  .np-blt .np-blt__list .np-blt__tag--slate { background: #ff9f2e; }
  /* 暗色模式下时间用略亮的灰，保证对比度 */
  body.np-dark .np-blt .np-blt__list .np-blt__time { color: #8b939d; }
}

/* 75.3 桌面：维持 BaoLog 紧凑单行，仅补极轻 hover 反馈 */
@media (min-width: 577px) {
  .np-blt[data-np-layout="split"] .np-blt__row { transition: background 140ms ease; }
  .np-blt[data-np-layout="split"] .np-blt__row:hover {
    background: color-mix(in srgb, var(--np-primary) 4%, transparent);
  }
}

/* 75.4 layout=stack：桌面 / 窄侧栏可显式选用「两行式」 */
.np-blt[data-np-layout="stack"] .np-blt__list .np-blt__row {
  flex-direction: column; align-items: flex-start; justify-content: flex-start;
  gap: 8px; min-height: 0; padding: 0; margin: 0 0 30px;
  border: 0; border-bottom: 0;
}
.np-blt[data-np-layout="stack"] .np-blt__list .np-blt__subject {
  display: block; width: 100%; max-width: 100%;
}
.np-blt[data-np-layout="stack"] .np-blt__list .np-blt__title {
  display: inline; max-width: 100%; font-size: 17px; font-weight: 500;
  white-space: normal; overflow: visible; text-overflow: clip;
}
.np-blt[data-np-layout="stack"] .np-blt__list .np-blt__tag {
  display: inline-block; margin: 0 0 0 8px; vertical-align: 2px;
  padding: 4px 12px; font-size: 13px; line-height: 1.5;
}
.np-blt[data-np-layout="stack"] .np-blt__list .np-blt__tag--orange { background: #ff9f2e; }
.np-blt[data-np-layout="stack"] .np-blt__list .np-blt__tag--red { background: #e8342a; }
.np-blt[data-np-layout="stack"] .np-blt__list .np-blt__tag--green { background: #2ead2e; }
.np-blt[data-np-layout="stack"] .np-blt__list .np-blt__tag--purple { background: #f0334e; }
.np-blt[data-np-layout="stack"] .np-blt__list .np-blt__tag--slate { background: #ff9f2e; }
.np-blt[data-np-layout="stack"] .np-blt__list .np-blt__time { margin-left: 0; font-size: 16px; color: #9aa1a9; }
.np-blt[data-np-layout="stack"] .np-blt__list .np-blt__flag { display: none; }
.np-blt[data-np-layout="stack"] .np-blt__tabs { justify-content: center; gap: 8px; margin: 4px 0 30px; }
.np-blt[data-np-layout="stack"] .np-blt__tab { padding: .6em 1.05em; font-size: 15px; line-height: 1.5; }
.np-blt[data-np-layout="stack"] .np-blt__tab + .np-blt__tab { margin-left: 0; }
body.np-dark .np-blt[data-np-layout="stack"] .np-blt__list .np-blt__time { color: #8b939d; }

/* 75.5 尊重「减少动态效果」 */
@media (prefers-reduced-motion: reduce) {
  .np-blt .np-blt__tab,
  .np-blt .np-blt__tag,
  .np-blt[data-np-layout="split"] .np-blt__row { transition: none; }
}

/* ==========================================================================
   第 76 章 · 1.8.91 线报列表：字号一比一还原 BaoLog 0.4.3 + 可调基准字号
   —— 纯末尾追加，1~75 章零改动；沿用 .np-blt 前缀，用 [data-np-blt] 把特异性
      提到 (0,4,0)，覆盖第 75 章手机端 / 窄侧栏按截图写死的放大 px。

   BaoLog 0.4.3 真实字号体系（css/baolog.css 第 9 行 `html,table{font-size:14px}`，
   全站字号 / 间距一律用 em 相对这 14px）：
     .subject h2                     font-size:.95em      = 13.3px  标题
     .num-font（继承根字号）           —                   = 14px    时间（等宽）
     .badge                          font-size:75%        = 10.5px  标签徽章
     .post-body .nav-item a           font-size:.9em       = 12.6px  Tab 胶囊
                                      padding:.4em 1.5em（相对自身 12.6px）
     .post-body .nav-item:nth-child(2) margin:0 1.5em      = 21px    胶囊间距（相对 li 的 14px）
   1.8.90 手机端按截图放大到 17/16/13/15px，且胶囊间距误用「相对胶囊自身 .9em」
   的 1.5em(=18.9px) 或 8/10px gap —— 与主题包不符。本版全部改回 em 相对基准。

   76.1 把根字号抽成 --np-blt-fs：默认 14px 即严格一比一；填 10~24 后，标题 /
        时间 / 标签 / Tab 字号与胶囊间距按同一比例整体等比缩放（正是 BaoLog 换
        html font-size 的机制），桌面与手机同步生效。
   76.2 布局（手机两行式 / 桌面 BaoLog 单行 / stack）一律不动，只还原字号与间距。
   ========================================================================== */

/* 76.1 基准字号：默认 14px = BaoLog html{font-size:14px}，可由 --np-blt-fs 覆盖 */
.np-blt[data-np-blt] { font-size: var(--np-blt-fs, 14px); }

/* 76.2 列表字号全部改回 em 相对基准（覆盖 72.6 / 72.9 / 75.1 / 75.2 / 75.4 写死的 px） */
.np-blt[data-np-blt] .np-blt__list .np-blt__title { font-size: .95em; }
.np-blt[data-np-blt] .np-blt__list .np-blt__time  { font-size: 1em; }
.np-blt[data-np-blt] .np-blt__list .np-blt__flag  { font-size: .95em; }
.np-blt[data-np-blt] .np-blt__list .np-blt__tag   { font-size: .75em; padding: .25em .6em; }

/* 76.3 Tab 胶囊：字号 .9em、内边距 .4em 1.5em（与 BaoLog 完全一致，随基准等比缩放） */
.np-blt[data-np-blt] .np-blt__tabs .np-blt__tab { font-size: .9em; padding: .4em 1.5em; }

/* 76.4 胶囊间距一比一 = 21px：BaoLog 是中间 li 左右各 margin 1.5em（相对 14px 根）。
   改用容器级 gap 1.5em（相对 .np-blt__tabs 继承的基准字号）= 21px，并清掉
   72.4 / 72.9 / 75.x 里「相对胶囊自身 .9em」的 margin-left（只有 18.9px）。 */
.np-blt[data-np-blt] .np-blt__tabs { gap: 1.5em; }
.np-blt[data-np-blt] .np-blt__tabs .np-blt__tab + .np-blt__tab { margin-left: 0; }

/* 76.5 尊重「减少动态效果」（沿用 75.5，覆盖后仍需保持） */
@media (prefers-reduced-motion: reduce) {
  .np-blt[data-np-blt] .np-blt__tab,
  .np-blt[data-np-blt] .np-blt__tag { transition: none; }
}


/* ==========================================================================
   第 77 章 · 1.8.92 页面分组小工具 + 论坛优化（参考 zibll.top / 子比）
   —— 纯末尾追加，1~76 章零改动。

   77.1 「按页面分组」新增论坛页面 / 线报页面 / 下载页面：三个模板各自
        显式输出 top / above / side / below / bottom 五个位置。区域容器带
        data-np-wa="分组-位置"，因此用属性前缀精确命中，不碰其它页面。
   77.2 论坛板块快选 chips（子比「板块列表 / 多栏目帖子列表」同款）。
   77.3 论坛列表头「发布主题」按钮。
   77.4 板块卡片「今日 N 帖」徽标。
   77.5 主题卡片「最后由 X 回复 · N 分钟前」。
   77.6 活跃用户榜（子比「用户排行榜模块」同款）。
   77.7 暗色 / 手机 / 减少动效。
   ========================================================================== */

/* 77.1 三个专用页面分组的区域间距（线性报窄栏与下载单列都安全） */
.np-wa[data-np-wa^="forum-"],
.np-wa[data-np-wa^="bulletin-"],
.np-wa[data-np-wa^="download-"] { margin: 18px 0 22px; }
.np-blt-embedded__main .np-wa { max-width: 100%; }

/* 论坛右侧栏里的「侧边栏」位置：和 npf-panel 同一套白卡观感 */
.npf-side .np-wa[data-np-wa="forum-side"] { margin: 0; }
.npf-side .np-wa[data-np-wa="forum-side"] .np-widget {
  background: var(--np-bg, #fff);
  border: 1px solid var(--np-line, #e6e9ee);
  border-radius: 12px;
  padding: 16px;
  box-shadow: var(--npf-shadow, 0 4px 16px rgba(20, 30, 45, .04));
}
.npf-side .np-wa[data-np-wa="forum-side"] .np-widget__title {
  margin: 0 0 12px;
  font-size: 15px;
}

/* 77.2 板块快选：横向可滚动的胶囊，窄屏不换行、不撑破页面 */
.npf-filter {
  display: flex;
  flex-wrap: nowrap;
  gap: 8px;
  overflow-x: auto;
  padding: 2px 0 12px;
  margin: 0 0 14px;
  scrollbar-width: thin;
  -webkit-overflow-scrolling: touch;
}
.npf-filter__i {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border: 1px solid var(--np-line, #e6e9ee);
  border-radius: 999px;
  background: var(--np-bg, #fff);
  color: var(--np-text-2, #50575e);
  font-size: 13px;
  line-height: 1.5;
  text-decoration: none;
  white-space: nowrap;
  transition: color .18s ease, border-color .18s ease, background-color .18s ease;
}
.npf-filter__i:hover { border-color: var(--np-primary); color: var(--np-primary); }
.npf-filter__i.is-active {
  border-color: transparent;
  background: var(--np-primary);
  color: #fff;
  font-weight: 600;
}
.npf-filter__today {
  display: inline-block;
  min-width: 16px;
  padding: 0 5px;
  border-radius: 999px;
  background: #e8342a;
  color: #fff;
  font-size: 11px;
  font-style: normal;
  line-height: 16px;
  text-align: center;
}
.npf-filter__i.is-active .npf-filter__today { background: rgba(255, 255, 255, .28); }

/* 77.3 列表头发布按钮：auto margin 吸收剩余空间，只在有按钮的标题栏生效 */
.npf-sec__post { margin-left: auto; padding: 6px 14px; font-size: 13px; white-space: nowrap; }
.npf-sec__post .npf-ico { width: 13px; height: 13px; flex-basis: 13px; }

/* 77.4 板块卡片的「今日 N 帖」 */
.npf-board__today {
  display: inline-flex;
  align-items: center;
  align-self: flex-start;
  gap: 5px;
  margin-top: 6px;
  color: #e8342a;
  font-size: 11px;
  font-weight: 600;
  white-space: nowrap;
}
.npf-board__today i { width: 6px; height: 6px; border-radius: 50%; background: #e8342a; }

/* 77.5 主题卡片「最后回复」 */
.npf-post__last {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 5px;
  margin: 0 0 12px;
  color: var(--np-muted, #8b939d);
  font-size: 12px;
}
.npf-post__last .npf-ico { width: 12px; height: 12px; flex-basis: 12px; }
.npf-post__last i { font-style: normal; opacity: .6; }

/* 77.6 活跃用户榜 */
.npf-users { list-style: none; margin: 0; padding: 0; }
.npf-users__li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 0;
  border-bottom: 1px solid var(--np-line, #eef0f3);
}
.npf-users__li:last-child { border-bottom: 0; }
.npf-users__no {
  flex: 0 0 20px;
  width: 20px;
  height: 20px;
  border-radius: 6px;
  background: #f0f2f5;
  color: #8b939d;
  font-size: 11px;
  font-weight: 700;
  line-height: 20px;
  text-align: center;
}
.npf-users__no--top { background: var(--np-primary); color: #fff; }
.npf-users__avatar {
  flex: 0 0 36px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--np-primary-soft, #eef4ff);
}
.npf-users__avatar .npf-avatar__img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; }
.npf-users__avatar .npf-avatar__fallback { font-size: 15px; font-weight: 700; color: var(--np-primary); }
.npf-users__info { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; }
.npf-users__name {
  font-size: 13px;
  color: var(--np-text-2, #1f2328);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.npf-users__meta { font-size: 11px; color: var(--np-muted, #8b939d); }

/* 77.7 暗色 / 手机 / 减少动效 */
body.np-dark .npf-filter__i {
  background: var(--np-bg, #1b2029);
  border-color: var(--np-line, #303845);
  color: var(--np-text-2, #a9b1bd);
}
body.np-dark .npf-filter__i.is-active { background: var(--np-primary); border-color: transparent; color: #fff; }
body.np-dark .npf-users__no { background: #2b323d; color: #a9b1bd; }
body.np-dark .npf-users__li { border-color: #2b323d; }
body.np-dark .npf-board__today { color: #ff7a70; }
body.np-dark .npf-board__today i { background: #ff7a70; }
body.np-dark .npf-side .np-wa[data-np-wa="forum-side"] .np-widget { border-color: #2b323d; }

@media (max-width: 576px) {
  .npf-filter { margin-left: -2px; margin-right: -2px; padding-left: 2px; padding-right: 2px; }
  .npf-sec__post { padding: 5px 10px; font-size: 12px; }
  .npf-sec__head .npf-sec__sub { display: none; }
  .np-wa[data-np-wa^="forum-"],
  .np-wa[data-np-wa^="bulletin-"],
  .np-wa[data-np-wa^="download-"] { margin: 14px 0 16px; }
}
@media (prefers-reduced-motion: reduce) {
  .npf-filter__i { transition: none; }
}


/* ==========================================================================
   第 80 章 · 1.8.95 首屏英雄区通栏白边修复 + 页面画布切块补全
   --------------------------------------------------------------------------
   问题 A：.np-hero--full 原来用 calc(50% - vw/2) 做通栏负 margin，其中 50%
   相对「父容器宽度与位置」。当英雄区被拖进带侧栏的内容列（above/main）时，
   父容器不居中，导致右侧留白边、左侧溢出。1.8.95 由 main.js 按每个英雄区
   的实际位置写入 --np-hero-ml（父容器左边缘到视口左边的距离），这里优先采用，
   只拉左侧一个负 margin 即精确铺满视口；无 JS 时退回原 calc 公式，顶部全宽
   场景（父容器居中）仍逐像素不变。
   问题 B：页面画布 autosplit 候选标签补全（在 page-builder.php 内），与本章
   样式无关，这里仅记录，保证 changelog 与实现一一对应。
   · 纯末尾追加，不改第 1~79 章一个字节；不改卡片宽度 / 圆角 / topbar 衔接。
   ========================================================================== */

/* 80.1 JS 已算出精确左偏移时：单侧负 margin 铺满视口，右侧清零避免重复拉伸。
   仅作用于通栏英雄区；--np-hero-mr 兜底为 0，避免继承旧的双侧负 margin。 */
.np-hero--full[style*="--np-hero-ml"] {
	margin-left: var(--np-hero-ml, 0px);
	margin-right: var(--np-hero-mr, 0px);
}

/* 80.2 卡片仍按视口宽居中，不随负 margin 偏移（保持 1.8.78 观感）。 */
.np-hero--full[style*="--np-hero-ml"] .np-hero__cards {
	width: min(calc(var(--np-vw, 1200px) - 40px), 1180px);
}

/* ==========================================================================
   第 81 章 · 1.8.96 手机端首屏英雄区右侧细小白边修复
   --------------------------------------------------------------------------
   现象：手机端首屏英雄区（通栏轮播）右侧有一条 1px 左右的白色细缝，桌面端
   因容器更宽、舍入比例更小而几乎看不出。
   根因（两处叠加）：
   ① 1.8.95 算通栏左偏移时只取了父容器的 paddingLeft，漏了 border。英雄区的
      小工具外壳 .np-widget 自带 1px 描边，于是英雄区整体右移 1px —— 左边露
      1px 白线、右边溢出 1px（实测 iPhone SE 375 / 12 390 / Plus 414 / 安卓
      360 全部 left=1.00、right=vw+1）。
   ② 英雄区宽度固定为「视口宽」，这个固定宽反过来把父容器（grid 项）撑到
      375px，页面 scrollWidth 比视口多出容器两侧内边距（实测 395 vs 375），
      整页可横向滑动，右侧就出现一条白缝。
   本版做法：main.js 同时写入 --np-hero-w / --np-hero-ml / --np-hero-mr，令英雄
   区的「外边距盒」恰好等于父内容宽 —— 既不撑宽父级、右边缘又精确落在视口
   右边；左偏移计入 border，左右都归零。无 JS 时仍走第 65 章原公式。
   · 纯末尾追加，不改第 1~80 章一个字节；不改卡片宽度 / 圆角 / topbar 衔接。
   ========================================================================== */

/* 81.1 通栏精确定位：宽度取视口宽，左右外边距由脚本算出的灰盒补偿。
   [data-np-fb] 由脚本写入，比 [style*="--np-hero-ml"] 更可靠（不受其它内联样式干扰）。 */
.np-hero--full[data-np-fb],
.np-hero--full[style*="--np-hero-ml"] {
	box-sizing: border-box;
	width: var(--np-hero-w, var(--np-vw, 100vw));
	min-width: 0;
	max-width: none;
	margin-left: var(--np-hero-ml, 0px);
	margin-right: var(--np-hero-mr, 0px);
}

/* 81.2 承载通栏英雄区的小工具外壳允许收缩，避免固定宽把它 / grid 项撑宽
   —— 这是「整页可横向滑动 + 右侧白缝」的直接原因。脚本会给 host 加 .np-hero-host。 */
.np-hero-host,
.np-wa--top > .np-hero-host,
.np-wa--bottom > .np-hero-host,
.np-wa--top > .np-hero--full,
.np-wa--bottom > .np-hero--full { min-width: 0; }

/* 81.3 卡片宽度：无 JS（--np-vw 未下发）时回退 100vw 而不是写死 1200px，
   否则手机上卡片会以 1160px 宽撑出整页横向滚动。有 JS 时 var 有值，结果不变。 */
.np-hero--full .np-hero__cards {
	width: min(calc(var(--np-vw, 100vw) - 40px), 1180px);
}

.np-hero--full[data-np-fb] .np-hero__cards,
.np-hero--full[style*="--np-hero-ml"] .np-hero__cards {
	width: min(calc(var(--np-vw, 100vw) - 40px), 1180px);
}


/* ==========================================================================
   第 82 章 · 1.9.0 沉浸式首屏下「网页翻译」下拉文字被顶栏染白修复
   --------------------------------------------------------------------------
   现象：开启沉浸式首屏（body.np-hero-immersive）时，点顶部「网页翻译」
   图标展开下拉，选中项「简体中文（原文）」文字是白色、背景是浅蓝灰，
   对比度不足几乎看不清；右侧「简」字却是深蓝，割裂。

   根因：沉浸顶栏为让图标在深色大图上可见，用
     body.np-hero-immersive .np-header:not(.is-solid) .np-header__actions a
     { color:#fff }（特异性 0,4,1）把顶栏操作区里所有 <a> 染白。桌面翻译
   菜单 .np-translate-menu 正挂在 .np-header__actions 下，其菜单项也是 <a>，
   于是被一起染白（.np-translate-menu__item.is-active 仅 0,2,0）；而 <em>
   简称不是 <a>、不受该规则影响仍是主色。抽屉版菜单不在顶栏操作区，正常。

   修复：在同等沉浸/非实心条件下，对 .np-header__actions 里的翻译菜单 <a>
   提到更高特异性，把文字还原为 var(--np-text-2)/选中 var(--np-primary)，
   背景 var(--np-bg)/var(--np-primary-soft)，并补回被染色的 padding 等仅
   作用于本菜单、不影响其它顶栏链接与按钮。菜单项本身是白底浅色卡片，
   深色字才可读；亮/暗色由 --np-* 令牌自动适配。纯末尾追加，不改 1~81 章。
   ========================================================================== */
body.np-hero-immersive .np-header:not(.is-solid) .np-header__actions .np-translate-menu a.np-translate-menu__item,
body.np-hero-immersive .np-header:not(.is-solid) .np-header__actions .np-translate-wrap .np-translate-menu a.np-translate-menu__item {
  color: var(--np-text-2);
  background: transparent;
}
body.np-hero-immersive .np-header:not(.is-solid) .np-header__actions .np-translate-menu a.np-translate-menu__item:hover,
body.np-hero-immersive .np-header:not(.is-solid) .np-header__actions .np-translate-wrap .np-translate-menu a.np-translate-menu__item:hover {
  color: var(--np-text);
  background: var(--np-bg-soft);
}
body.np-hero-immersive .np-header:not(.is-solid) .np-header__actions .np-translate-menu a.np-translate-menu__item.is-active,
body.np-hero-immersive .np-header:not(.is-solid) .np-header__actions .np-translate-wrap .np-translate-menu a.np-translate-menu__item.is-active {
  color: var(--np-primary);
  background: var(--np-primary-soft);
}
body.np-hero-immersive .np-header:not(.is-solid) .np-header__actions .np-translate-menu a.np-translate-menu__item em,
body.np-hero-immersive .np-header:not(.is-solid) .np-header__actions .np-translate-wrap .np-translate-menu a.np-translate-menu__item em {
  color: var(--np-muted);
}
body.np-hero-immersive .np-header:not(.is-solid) .np-header__actions .np-translate-menu a.np-translate-menu__item.is-active em,
body.np-hero-immersive .np-header:not(.is-solid) .np-header__actions .np-translate-wrap .np-translate-menu a.np-translate-menu__item.is-active em {
  color: var(--np-primary);
}
