/* ============================================================
   个人海报与人脉 板块 共用样式
   依赖 style.css 的 CSS 变量与设计体系
   ============================================================ */

/* ===== 功能面板内「返回首页」 ===== */
.ns-back {
  display: inline-block;
  margin-bottom: 12px;
  padding: 6px 14px;
  font-size: 13px;
  font-weight: 600;
  color: var(--primary);
  background: rgba(108, 92, 231, 0.08);
  border-radius: 20px;
  cursor: pointer;
  user-select: none;
}
.ns-back:active { background: rgba(108, 92, 231, 0.16); }

/* ===== 搜索框 ===== */
.ns-search {
  position: relative;
  margin-bottom: 12px;
}
.ns-search input {
  width: 100%;
  box-sizing: border-box;
  padding: 11px 16px 11px 40px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: #fff;
  font-size: 14px;
  color: var(--text);
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
.ns-search input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(108,92,231,.12);
}
.ns-search::before {
  content: '🔍';
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 15px;
  opacity: .6;
}

/* ===== 二级筛选（地区 / 行业 / 需求）===== */
.ns-filters {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 14px;
}
.ns-filters select {
  width: 100%;
  box-sizing: border-box;
  padding: 9px 8px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: #fff;
  font-size: 13px;
  color: var(--text);
  outline: none;
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3e%3cpath fill='%23B2BEC3' d='M0 0l5 6 5-6z'/%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 10px center;
  cursor: pointer;
}
.ns-filters select:focus { border-color: var(--primary); }

/* ===== 顶部 4 大 Tab 导航（人脉 / 个人展示 / 人脉拓展 / 我的名片）===== */
.nctabs {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  background: var(--card-bg);
  border-bottom: 1px solid var(--border);
  margin: 0 -14px 12px;
  padding: 0 6px;
  -webkit-overflow-scrolling: touch;
}
.nctab {
  flex: 1 1 0;
  text-align: center;
  padding: 13px 4px 11px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-muted);
  position: relative;
  cursor: pointer;
  user-select: none;
  white-space: nowrap;
  transition: color .15s;
}
.nctab:active { color: var(--primary); }
.nctab.active { color: var(--primary); }
.nctab.active::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  width: 26px;
  height: 3px;
  border-radius: 3px;
  background: var(--primary);
}

/* ===== 我的名片：子标签（资料与海报 / 视频图文 / 项目介绍 / 产品介绍） ===== */
.ncsubtabs {
  display: flex;
  gap: 6px;
  background: var(--bg-soft, #f4f5f7);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 4px;
  margin-bottom: 14px;
  position: sticky;
  top: 52px;
  z-index: 20;
}
.ncsubtab {
  flex: 1 1 0;
  text-align: center;
  padding: 9px 2px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  border-radius: 9px;
  cursor: pointer;
  user-select: none;
  white-space: nowrap;
  transition: all .15s;
}
.ncsubtab.active {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 2px 8px rgba(108,92,231,.28);
}
.ncsubpanel { animation: ncFade .2s ease; }
@keyframes ncFade { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

/* 产品卡片：编辑/价格 */
.np-proj-item .pp-edit {
  position: absolute;
  top: 10px;
  right: 52px;
  border: none;
  background: rgba(108,92,231,.12);
  color: var(--primary);
  font-size: 12px;
  font-weight: 700;
  border-radius: 8px;
  padding: 3px 9px;
  cursor: pointer;
}
.np-proj-item .pp-price {
  display: inline-block;
  margin-top: 4px;
  font-size: 13px;
  font-weight: 700;
  color: #e8453c;
  background: rgba(232,69,60,.1);
  padding: 2px 8px;
  border-radius: 6px;
}
.np-proj-item .pp-desc { font-size: 12.5px; color: var(--text-light); line-height: 1.5; white-space: pre-wrap; }

/* ===== 人脉拓展：匹配理由 / 换一批 ===== */
.nt-exp-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}
.nt-exp-tip { font-size: 13px; color: var(--text-muted); }
.nt-exp-refresh {
  font-size: 13px;
  font-weight: 600;
  color: var(--primary);
  background: rgba(108, 92, 231, 0.08);
  border: none;
  border-radius: 20px;
  padding: 7px 14px;
  cursor: pointer;
}
.nt-exp-refresh:active { background: rgba(108, 92, 231, 0.16); }
.nc-reason {
  display: inline-block;
  margin-top: 6px;
  font-size: 11px;
  color: #b06a00;
  background: #fff4e0;
  border-radius: 10px;
  padding: 2px 8px;
}

/* ===== 顶部大分类 Tab 调整（沿用 .tabs，这里加一点间距）===== */
#section-tabs { margin-bottom: 12px; }

/* ===== 人员名片卡片 ===== */
.nc-card {
  display: flex;
  gap: 12px;
  background: var(--card-bg);
  border-radius: var(--radius);
  padding: 14px;
  box-shadow: var(--shadow);
  margin-bottom: 12px;
  cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease;
  position: relative;
}
.nc-card:active {
  transform: scale(.985);
  box-shadow: var(--shadow-lg);
}

.nc-avatar {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--primary-light), var(--accent));
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 22px;
  font-weight: 800;
  flex-shrink: 0;
  overflow: hidden;
}
.nc-avatar img { width: 100%; height: 100%; object-fit: cover; }

.nc-main { flex: 1; min-width: 0; }
.nc-name {
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.nc-role {
  font-size: 11px;
  font-weight: 600;
  color: var(--primary);
  background: rgba(108,92,231,.1);
  padding: 1px 8px;
  border-radius: 10px;
  flex-shrink: 0;
}
.nc-meta {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.nc-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 7px;
}
.nc-tags .tag {
  font-size: 11px;
  font-weight: 600;
  padding: 2px 9px;
  border-radius: 10px;
}
.nc-tags .tag-ind { background: rgba(108,92,231,.1); color: var(--primary); }
.nc-tags .tag-need { background: rgba(0,206,201,.12); color: var(--accent-dark); }
.nc-slogan {
  font-size: 12.5px;
  color: var(--text-light);
  margin-top: 8px;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.nc-side {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-content: space-between;
  flex-shrink: 0;
  min-width: 64px;
}
.nc-score {
  font-size: 11px;
  font-weight: 700;
  color: #E17055;
  background: rgba(225,112,85,.1);
  padding: 3px 8px;
  border-radius: 10px;
  white-space: nowrap;
}
/* 列表右侧：天赋数字密码小圆圈（详情页「能量圈」缩小版） */
.nc-energy {
  flex-shrink: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  width: 40px; height: 40px; border-radius: 50%;
  background: linear-gradient(135deg, #C8F0E2, #C2E6FF);
  border: 1px solid rgba(63,122,107,.25);
  cursor: help;
}
.nc-energy-num { font-size: 18px; font-weight: 800; line-height: 1; color: #2F6B5A; }
.nc-energy-empty { background: rgba(150,150,150,.12); border-color: rgba(120,120,120,.2); }
.nc-energy-empty .nc-energy-num { color: #9aa0a6; font-weight: 600; }
.nc-greet {
  margin-top: 8px;
  font-size: 12px;
  padding: 7px 12px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  border: none;
  font-weight: 600;
  box-shadow: var(--shadow);
}
.nc-greet:active { transform: scale(.95); }

/* ===== 浮窗发布 / 编辑入口 ===== */
.ns-fab {
  position: fixed;
  right: 18px;
  bottom: calc(80px + var(--safe-bottom));
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  color: #fff;
  font-size: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-lg);
  z-index: 150;
  border: none;
}
.ns-fab:active { transform: scale(.93); }

/* ============================================================
   名片详情页
   ============================================================ */
.cd-hero {
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  border-radius: var(--radius-lg);
  padding: 22px 18px 18px;
  color: #fff;
  text-align: center;
  position: relative;
  margin-bottom: 14px;
  box-shadow: var(--shadow-lg);
}
.cd-hero .cd-back {
  position: absolute;
  left: 14px;
  top: 14px;
  width: 32px; height: 32px;
  border-radius: 50%;
  background: rgba(255,255,255,.2);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 18px;
}
.cd-hero .cd-sec-badge {
  position: absolute;
  right: 14px; top: 16px;
  font-size: 12px;
  font-weight: 700;
  background: rgba(255,255,255,.22);
  padding: 4px 12px;
  border-radius: 999px;
}
.cd-avatar {
  width: 88px; height: 88px;
  border-radius: 50%;
  margin: 6px auto 10px;
  border: 3px solid rgba(255,255,255,.7);
  background: rgba(255,255,255,.2);
  display: flex; align-items: center; justify-content: center;
  font-size: 34px; font-weight: 800;
  overflow: hidden;
}
.cd-avatar img { width: 100%; height: 100%; object-fit: cover; }
.cd-name { font-size: 21px; font-weight: 800; }
.cd-sub { font-size: 13px; opacity: .9; margin-top: 4px; }
.cd-stats {
  display: flex;
  justify-content: center;
  gap: 22px;
  margin-top: 14px;
}
.cd-stat { text-align: center; }
.cd-stat .v { font-size: 18px; font-weight: 800; }
.cd-stat .l { font-size: 11px; opacity: .85; margin-top: 2px; }

.cd-section {
  background: var(--card-bg);
  border-radius: var(--radius);
  padding: 16px;
  box-shadow: var(--shadow);
  margin-bottom: 12px;
}
.cd-section h3 {
  font-size: 15px;
  font-weight: 800;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.cd-section h3 .bar {
  width: 4px; height: 15px;
  background: var(--primary);
  border-radius: 3px;
}
.cd-about { font-size: 14px; color: var(--text-light); line-height: 1.7; white-space: pre-wrap; }
.cd-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.cd-tags .t {
  font-size: 12px; font-weight: 600;
  padding: 4px 11px; border-radius: 12px;
}
.cd-tags .t-ind { background: rgba(108,92,231,.1); color: var(--primary); }
.cd-tags .t-need { background: rgba(0,206,201,.12); color: var(--accent-dark); }
.cd-tags .t-role { background: rgba(253,203,110,.18); color: #E17055; }

/* 联系方式行 */
.cd-contact-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}
.cd-contact-row:last-child { border-bottom: none; }
.cd-contact-row .ic {
  width: 36px; height: 36px;
  border-radius: 10px;
  background: rgba(108,92,231,.1);
  display: flex; align-items: center; justify-content: center;
  font-size: 17px; flex-shrink: 0;
}
.cd-contact-row .ct { flex: 1; min-width: 0; }
.cd-contact-row .ct .k { font-size: 11px; color: var(--text-muted); }
.cd-contact-row .ct .val {
  font-size: 14px; font-weight: 600; color: var(--text);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.cd-copy {
  font-size: 12px; font-weight: 700;
  color: var(--primary);
  background: rgba(108,92,231,.08);
  border: none; padding: 6px 12px; border-radius: 999px;
  flex-shrink: 0;
}
.cd-copy:active { transform: scale(.95); }

/* 项目 / 产品 / 风采 */
.cd-project {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px;
  margin-bottom: 10px;
}
.cd-project:last-child { margin-bottom: 0; }
.cd-project .pt {
  font-size: 14px; font-weight: 700; color: var(--text);
  display: flex; align-items: center; gap: 6px;
}
.cd-project .pt .ptype {
  font-size: 10px; font-weight: 700; padding: 1px 7px; border-radius: 8px;
  background: rgba(0,206,201,.14); color: var(--accent-dark);
}
.cd-project .pd { font-size: 13px; color: var(--text-light); margin-top: 6px; line-height: 1.6; }
.cd-project .pimgs { display: flex; gap: 6px; margin-top: 8px; flex-wrap: wrap; }
.cd-project .pimgs img {
  width: 80px; height: 80px; object-fit: cover; border-radius: 10px; background: #f0f0f0;
}
.cd-project .plink {
  display: inline-block; margin-top: 8px;
  font-size: 12px; color: var(--primary); font-weight: 600;
}

/* 底部操作条 */
.cd-bottom-bar {
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  bottom: 0;
  width: 100%;
  max-width: 480px;
  display: flex;
  gap: 10px;
  padding: 10px 16px calc(10px + var(--safe-bottom));
  background: rgba(255,255,255,.98);
  backdrop-filter: blur(20px);
  border-top: 1px solid var(--border);
  z-index: 200;
}
.cd-bottom-bar .btn { flex: 1; }

/* 个人展示底部分享条 */
.ns-share-bar {
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  bottom: calc(64px + var(--safe-bottom));
  width: 100%;
  max-width: 480px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 10px 16px calc(8px + var(--safe-bottom));
  background: rgba(255,255,255,.98);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-top: 1px solid var(--border);
  z-index: 210;
}
.ns-share-bar .ns-share-btn { width: 100%; font-weight: 700; }
.ns-share-bar .ns-same-link {
  font-size: 12px; color: var(--text-muted);
  text-decoration: none; padding: 2px 0;
}
.ns-share-bar .ns-same-link:active { color: var(--primary); }

/* 个人展示 tab（network-center）内嵌分享区：覆盖 .ns-share-bar 的 fixed 定位，改为页面内非浮动 */
#ds-share-bar {
  position: static;
  left: auto; transform: none; bottom: auto;
  width: 100%; max-width: none;
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  padding: 16px 0 4px;
  background: none;
  backdrop-filter: none; -webkit-backdrop-filter: none;
  border-top: 1px solid var(--border);
  z-index: auto;
}
#ds-share-bar .ns-share-btn { width: 100%; font-weight: 700; }
#ds-share-bar .ns-same-link {
  font-size: 13px; color: var(--primary); white-space: nowrap;
  text-decoration: none; font-weight: 600; line-height: 1; padding: 2px 0;
}

/* 分享面板（兜底）：复制链接 + 微信引导 */
.ns-sheet-mask {
  position: fixed; inset: 0; z-index: 1000;
  background: rgba(0,0,0,.5);
  display: none; align-items: flex-end; justify-content: center;
}
.ns-sheet-mask.show { display: flex; }
.ns-sheet {
  width: 100%; max-width: 480px;
  background: #fff; border-radius: 16px 16px 0 0;
  padding: 18px 16px calc(18px + var(--safe-bottom));
  display: flex; flex-direction: column; gap: 12px;
}
.ns-sheet-title { font-size: 15px; font-weight: 700; text-align: center; color: var(--text); }
.ns-sheet-link {
  font-size: 13px; color: var(--text-light);
  background: var(--bg-soft, #f4f5f7); border: 1px solid var(--border);
  border-radius: 10px; padding: 10px 12px;
  word-break: break-all; line-height: 1.5;
}
.ns-sheet-tip { font-size: 12px; color: var(--text-muted); line-height: 1.5; text-align: center; }

/* ------------------------------------------------------------
   微信内分享引导浮层
   微信禁止页面用 JS 主动唤起「发送给朋友」面板，只能把分享内容配置给右上角「···」。
   故这里给出明确指引 + 好友将看到的卡片预览。
   ★ 刻意不展示链接文本：展示链接会让用户误以为「分享出去的是链接」。
   ------------------------------------------------------------ */
.ns-wxguide {
  position: fixed; inset: 0; z-index: 2000;
  background: rgba(0,0,0,.72);
  display: none; flex-direction: column;
  padding: calc(14px + var(--safe-top, 0px)) 16px calc(20px + var(--safe-bottom, 0px));
}
.ns-wxguide.show { display: flex; }
.ns-wxguide-arrow { align-self: flex-end; margin-right: 2px; }
.ns-wxguide-arrow svg {
  display: block; width: 72px; height: 72px;
  animation: nsWxArrowMove 1.15s ease-in-out infinite;
}
@keyframes nsWxArrowMove {
  0%, 100% { transform: translate(0, 0); }
  50% { transform: translate(6px, -6px); }
}
.ns-wxguide-tip {
  align-self: flex-end; margin-right: 10px; margin-top: 2px;
  color: #fff; font-size: 15px; font-weight: 700; letter-spacing: .5px;
  text-shadow: 0 1px 3px rgba(0,0,0,.4);
}
.ns-wxguide-card {
  margin-top: auto; align-self: center;
  width: 100%; max-width: 420px;
  background: #fff; border-radius: 16px;
  padding: 18px 16px 14px;
  display: flex; flex-direction: column; gap: 11px;
}
.ns-wxguide-title {
  font-size: 16px; font-weight: 800; color: var(--text);
  text-align: center; display: flex; align-items: center; justify-content: center; gap: 6px;
}
.ns-wxguide-badge {
  font-size: 11px; font-weight: 700; color: #fff;
  background: #07c160; border-radius: 999px; padding: 2px 7px;
}
.ns-wxguide-preview {
  display: flex; align-items: center; gap: 10px;
  background: var(--bg-soft, #f4f5f7);
  border: 1px solid var(--border);
  border-radius: 12px; padding: 10px;
}
.ns-wxguide-thumb {
  width: 52px; height: 52px; flex: 0 0 auto;
  border-radius: 8px; object-fit: cover; background: #e9e9f2;
}
.ns-wxguide-meta { min-width: 0; flex: 1; }
.ns-wxguide-name {
  font-size: 14px; font-weight: 700; color: var(--text);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.ns-wxguide-desc {
  font-size: 12px; color: var(--text-muted); margin-top: 3px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.ns-wxguide-steps { font-size: 14px; color: var(--text-light); line-height: 1.9; }
.ns-wxguide-steps .idx {
  display: inline-block; width: 18px; height: 18px; line-height: 18px; text-align: center;
  border-radius: 50%; background: var(--primary); color: #fff;
  font-size: 11px; font-weight: 700; margin-right: 7px;
}
.ns-wxguide-steps b { color: var(--primary); }
.ns-wxguide-note {
  font-size: 12px; color: var(--text-muted); line-height: 1.5; text-align: center;
}
.ns-wxguide-copy {
  border: 0; background: transparent; padding: 4px 0;
  font-size: 12px; color: var(--text-muted);
  text-decoration: underline; cursor: pointer;
}
/* 分享接口授权状态说明条（checkJsApi 探测结果） */
.ns-wxguide-perm {
  display: block; font-size: 12.5px; line-height: 1.55;
  background: #e9f9ef; color: #1a7f47;
  border: 1px solid #bfe9d0; border-radius: 10px; padding: 8px 10px;
}
.ns-wxguide-perm.warn {
  background: #fff7e6; color: #9a6700; border-color: #ffd591;
}

/* ===== 「发送名片图片」浮层（长按图片→发送给朋友，不依赖公众号权限） ===== */
.ns-imgsend {
  position: fixed; inset: 0; z-index: 2100;
  background: rgba(0,0,0,.78);
  display: none; flex-direction: column; align-items: center; justify-content: flex-start;
  overflow-y: auto; -webkit-overflow-scrolling: touch;
  padding: 20px 20px calc(20px + var(--safe-bottom, 0px));
}
.ns-imgsend.show { display: flex; }
.ns-imgsend > :first-child { margin-top: auto; }
.ns-imgsend > :last-child { margin-bottom: auto; }
.ns-imgsend-title {
  color: #fff; font-size: 17px; font-weight: 800; margin-bottom: 6px; text-align: center;
  text-shadow: 0 1px 4px rgba(0,0,0,.4);
}
.ns-imgsend-sub {
  color: rgba(255,255,255,.88); font-size: 13px; margin-bottom: 14px; text-align: center; line-height: 1.5;
}
.ns-imgsend-img {
  max-width: 86%; max-height: 70vh; border-radius: 14px;
  box-shadow: 0 12px 40px rgba(0,0,0,.45); background: #fff;
}
.ns-imgsend-tip {
  color: #fff; font-size: 13px; line-height: 1.7; margin-top: 14px; text-align: center;
  background: rgba(255,255,255,.12); border-radius: 10px; padding: 10px 14px;
}
.ns-imgsend-tip b { color: #ffe08a; }
.ns-imgsend-close {
  margin-top: 16px; width: 200px; background: #fff; color: #333;
  border: 0; border-radius: 999px; padding: 11px 0; font-size: 15px; font-weight: 700; cursor: pointer;
}

/* ============================================================
   名片编辑页
   ============================================================ */
.np-edit-hint {
  font-size: 12px;
  color: var(--text-muted);
  background: rgba(108,92,231,.06);
  border: 1px dashed var(--primary-light);
  border-radius: 10px;
  padding: 10px 12px;
  margin-bottom: 14px;
  line-height: 1.6;
}
.np-edit-hint a { font-weight: 700; }

/* 多选标签组 */
.multi-group { margin-bottom: 14px; }
.multi-group .mg-label {
  font-size: 14px; font-weight: 700; color: var(--text);
  margin-bottom: 8px; display: flex; align-items: center; gap: 6px;
}
.multi-group .mg-label .bar {
  width: 4px; height: 15px; background: var(--primary); border-radius: 3px;
}
.multi-pills { display: flex; flex-wrap: wrap; gap: 8px; }
.multi-pill {
  font-size: 13px; font-weight: 600;
  padding: 7px 14px;
  border-radius: 999px;
  background: #fff; color: var(--text-light);
  border: 1px solid var(--border);
  cursor: pointer;
  transition: all .15s;
  user-select: none;
}
.multi-pill.active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

/* 开关行 */
.np-switch-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 0;
}
.np-switch-row .lab { font-size: 14px; font-weight: 600; color: var(--text); }
.np-switch-row .desc { font-size: 12px; color: var(--text-muted); margin-top: 2px; }

/* 项目 / 产品 / 风采 编辑 */
.np-proj-item {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px;
  margin-bottom: 10px;
  position: relative;
}
.np-proj-item .pp-type {
  font-size: 11px; font-weight: 700; color: var(--accent-dark);
  background: rgba(0,206,201,.14); padding: 2px 8px; border-radius: 8px;
}
.np-proj-item .pp-title { font-size: 14px; font-weight: 700; margin: 6px 0 2px; }
.np-proj-item .pp-desc { font-size: 12.5px; color: var(--text-light); line-height: 1.5; }
.np-proj-item .pp-del {
  position: absolute; right: 10px; top: 10px;
  font-size: 12px; color: #E17055; background: rgba(225,112,85,.1);
  border: none; padding: 4px 10px; border-radius: 999px; font-weight: 600;
}
/* 项目卡片内图片（只读展示） */
.np-proj-item .np-proj-imgs { display: flex; gap: 6px; margin-top: 8px; flex-wrap: wrap; }
.np-proj-item .np-proj-imgs img { width: 72px; height: 72px; object-fit: cover; border-radius: 8px; display: block; }
.np-proj-item .plink { display: inline-block; margin-top: 8px; color: var(--primary); font-size: 13px; font-weight: 700; }
.np-proj-add {
  width: 100%;
  border: 1.5px dashed var(--primary-light);
  background: rgba(108,92,231,.04);
  color: var(--primary);
  font-weight: 700;
  padding: 12px;
  border-radius: 12px;
  font-size: 14px;
}

/* 「我的名片」底部保存按钮（页面流内，位于内容最底部，不被底部导航遮挡） */
.mine-save-wrap { padding: 18px 16px 10px; }
.mine-save-wrap .mine-save-tip { margin: 8px 0 0; font-size: 12px; color: var(--text-muted); text-align: center; }

/* 保存条（历史遗留，已改用页面流内按钮，保留样式以便复用） */
.save-bar {
  position: fixed;
  left: 50%; transform: translateX(-50%);
  bottom: 0; width: 100%; max-width: 480px;
  padding: 10px 16px calc(10px + var(--safe-bottom));
  background: rgba(255,255,255,.98);
  backdrop-filter: blur(20px);
  border-top: 1px solid var(--border);
  z-index: 200;
}

/* 招呼弹窗文案输入 */
.greet-input {
  width: 100%;
  box-sizing: border-box;
  min-height: 90px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 12px;
  font-size: 14px;
  font-family: inherit;
  resize: vertical;
  outline: none;
}
.greet-input:focus { border-color: var(--primary); }
.greet-quick {
  display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0 14px;
}
.greet-quick span {
  font-size: 12px; color: var(--text-light);
  background: var(--bg); border: 1px solid var(--border);
  padding: 5px 10px; border-radius: 999px; cursor: pointer;
}

/* ============================================================
   三大板块 HUB 入口页
   ============================================================ */
.ns-hub-hero {
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  border-radius: var(--radius-lg);
  padding: 22px 18px;
  color: #fff;
  margin-bottom: 16px;
  box-shadow: var(--shadow-lg);
}
.ns-hero-title { font-size: 19px; font-weight: 800; }
.ns-hero-sub { font-size: 13px; opacity: .9; margin-top: 6px; }

.ns-hub-list { display: flex; flex-direction: column; gap: 12px; }
.ns-hub-card {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--card-bg);
  border-radius: var(--radius);
  padding: 16px;
  box-shadow: var(--shadow);
  text-decoration: none;
  color: var(--text);
  position: relative;
  overflow: hidden;
  transition: transform .15s ease;
}
.ns-hub-card:active { transform: scale(.985); }
.ns-hub-card::after {
  content: ''; position: absolute; right: -30px; top: -30px;
  width: 100px; height: 100px; border-radius: 50%; opacity: .1;
}
.ns-hub-showcase::after { background: #6C5CE7; }
.ns-hub-network::after { background: #00CEC9; }
.ns-hub-business::after { background: #FDCB6E; }
.ns-hub-icon {
  width: 50px; height: 50px; border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  font-size: 26px; flex-shrink: 0;
}
.ns-hub-showcase .ns-hub-icon { background: rgba(108,92,231,.12); }
.ns-hub-network .ns-hub-icon { background: rgba(0,206,201,.14); }
.ns-hub-business .ns-hub-icon { background: rgba(253,203,110,.2); }
.ns-hub-body { flex: 1; min-width: 0; }
.ns-hub-name { font-size: 16px; font-weight: 800; }
.ns-hub-desc { font-size: 12.5px; color: var(--text-muted); margin-top: 3px; line-height: 1.5; }
.ns-hub-arrow { font-size: 22px; color: var(--text-muted); flex-shrink: 0; }
.ns-hub-tip { font-size: 12px; color: var(--text-muted); margin-top: 16px; line-height: 1.6; }
.ns-hub-tip a { color: var(--primary); font-weight: 700; }

/* ============================================================
   个人展示 · 海报工作台
   ============================================================ */
.ns-show-layout { display: flex; gap: 14px; align-items: flex-start; }
.ns-preview-wrap { width: 42%; flex-shrink: 0; position: sticky; top: 12px; }
.ns-preview {
  width: 100%;
  aspect-ratio: 9 / 16;
  border-radius: 16px;
  background: linear-gradient(135deg,#6C5CE7,#A29BFE);
  color: #fff;
  padding: 18px 14px;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}
.pv-avatar {
  width: 56px; height: 56px; border-radius: 50%;
  background: rgba(255,255,255,.25);
  border: 2px solid rgba(255,255,255,.7);
  display: flex; align-items: center; justify-content: center;
  font-size: 24px; font-weight: 800; overflow: hidden;
  margin-top: 6px;
}
.pv-avatar img { width: 100%; height: 100%; object-fit: cover; }
.pv-name { font-size: 17px; font-weight: 800; margin-top: 8px; }
.pv-slogan { font-size: 12px; opacity: .92; margin-top: 4px; min-height: 14px;
  display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; }
.pv-meta { font-size: 11px; opacity: .82; margin-top: 5px; }
.pv-divider { width: 60%; height: 1px; background: rgba(255,255,255,.4); margin: 12px 0; }
.pv-section-label { font-size: 11px; font-weight: 700; color: #FFEAA7; align-self: flex-start; margin: 4px 0 6px; }
.ns-preview .pv-tags { display: flex; flex-wrap: wrap; gap: 5px; align-self: flex-start; width: 100%; }
.pv-tag {
  font-size: 10.5px; font-weight: 600;
  background: rgba(255,255,255,.22);
  padding: 3px 9px; border-radius: 10px;
}
.pv-about {
  font-size: 11.5px; opacity: .92; line-height: 1.6; margin-top: 10px; align-self: flex-start;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.pv-qr { margin-top: auto; display: flex; flex-direction: column; align-items: center; }
.pv-qr-box {
  width: 64px; height: 64px; background: #fff; border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; color: #999; font-weight: 600;
}
.pv-qr-tip { font-size: 10px; opacity: .85; margin-top: 5px; }

.ns-edit-col { flex: 1; min-width: 0; }
.ns-themes { display: flex; gap: 10px; }
.ns-theme {
  width: 44px; height: 44px; border-radius: 12px; cursor: pointer;
  border: 3px solid transparent; box-shadow: var(--shadow);
}
.ns-theme.active { border-color: var(--text); }

.ns-result-title { font-size: 14px; font-weight: 700; color: var(--primary); margin: 18px 0 10px; }
.ns-result-img {
  width: 100%; max-width: 280px; display: block; margin: 0 auto 12px;
  border-radius: 14px; box-shadow: var(--shadow-lg);
}

.ns-mine { margin-top: 22px; }
.ns-mine-title { font-size: 15px; font-weight: 800; display: flex; align-items: center; gap: 6px; margin-bottom: 12px; }
.ns-mine-title .bar { width: 4px; height: 15px; background: var(--primary); border-radius: 3px; }
.ns-mine-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.ns-mine-item { position: relative; border-radius: 12px; overflow: hidden; box-shadow: var(--shadow); }
.ns-mine-item img { width: 100%; aspect-ratio: 9/16; object-fit: cover; display: block; }
.ns-mine-del {
  position: absolute; right: 4px; top: 4px;
  width: 22px; height: 22px; border-radius: 50%;
  background: rgba(0,0,0,.55); color: #fff; border: none;
  font-size: 14px; line-height: 1; display: flex; align-items: center; justify-content: center;
}

/* ============================================================
   商机板块
   ============================================================ */
.ns-biz-types { display: flex; gap: 8px; }
.ns-biz-type {
  flex: 1; text-align: center;
  font-size: 13px; font-weight: 700; color: var(--text-light);
  padding: 9px 0; border-radius: 999px;
  background: var(--bg); border: 1px solid var(--border); cursor: pointer;
}
.ns-biz-type.active { background: var(--primary); color: #fff; border-color: var(--primary); }

.ns-pub-types { display: flex; gap: 8px; }
.ns-pub-type {
  flex: 1; text-align: center;
  font-size: 13px; font-weight: 700; color: var(--text-light);
  padding: 10px 0; border-radius: 12px;
  background: var(--bg); border: 1px solid var(--border); cursor: pointer;
}
.ns-pub-type.active { background: var(--primary); color: #fff; border-color: var(--primary); }

.biz-card {
  background: var(--card-bg); border-radius: var(--radius);
  padding: 14px; box-shadow: var(--shadow); margin-bottom: 12px;
}
.biz-top { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.biz-badge {
  font-size: 11px; font-weight: 700; padding: 3px 10px; border-radius: 999px;
}
.biz-badge.supply { background: rgba(0,184,148,.14); color: #00B894; }
.biz-badge.demand { background: rgba(225,112,85,.14); color: #E17055; }
.biz-urgent { font-size: 11px; font-weight: 700; color: #E17055; background: rgba(225,112,85,.12); padding: 3px 9px; border-radius: 999px; }
.biz-del { margin-left: auto; font-size: 12px; color: var(--text-muted); background: none; border: none; cursor: pointer; }
.biz-title { font-size: 16px; font-weight: 800; color: var(--text); line-height: 1.4; }
.biz-content { font-size: 13px; color: var(--text-light); margin-top: 6px; line-height: 1.6; white-space: pre-wrap; }
.biz-meta { font-size: 12px; color: var(--text-muted); margin-top: 8px; }
.biz-contact { font-size: 12px; color: var(--primary); margin-top: 6px; font-weight: 600; }
.biz-foot { display: flex; align-items: center; justify-content: space-between; margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--border); }
.biz-author { display: flex; align-items: center; gap: 7px; font-size: 12.5px; color: var(--text); }
.biz-avatar {
  width: 26px; height: 26px; border-radius: 50%;
  background: linear-gradient(135deg, var(--primary-light), var(--accent));
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 12px; font-weight: 700; overflow: hidden;
}
.biz-avatar img { width: 100%; height: 100%; object-fit: cover; }
.biz-time { font-size: 11px; color: var(--text-muted); }

.modal-lg { max-width: 440px; max-height: 86vh; overflow-y: auto; /* 底部留白：让贴底固定的 .cd-bottom-bar（转发/加好友/打招呼）不遮挡最后一段内容 */ padding-bottom: calc(88px + var(--safe-bottom)); }

/* ============================================================
   个人展示页 · 顶部只读信息卡 + 照片上传网格
   ============================================================ */

/* 隐藏真正的 file input，但保留可被 label 触发（避免移动端 hidden/display:none 无法呼出相册） */
.ns-hidden-input {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
  opacity: 0;
}

/* ===== 个人展示 · 名片式资料卡（马卡龙浅色系） ===== */
.ns-bizcard {
  position: relative;
  border-radius: 18px;
  overflow: hidden;
  background: linear-gradient(160deg, #FFFBFE 0%, #F7F0FF 100%);
  border: 1px solid #F0E2F2;
  box-shadow: 0 6px 20px rgba(196,160,210,.22);
}
.ns-bc-header {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 13px 16px;
  background: linear-gradient(135deg, #FFD6E8 0%, #D9C7FF 100%);
  color: #6B4F7A;
}
.ns-bc-org { display: flex; align-items: center; gap: 10px; min-width: 0; }
.ns-bc-logo {
  width: 34px; height: 34px; border-radius: 9px; flex-shrink: 0;
  background: rgba(255,255,255,.55);
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 16px; color: #7A4F8B;
}
.ns-bc-orgname {
  font-size: 14px; font-weight: 700; color: #6B4F7A;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.ns-bc-energy {
  flex-shrink: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  width: 52px; height: 52px; border-radius: 50%;
  background: linear-gradient(135deg, #C8F0E2, #C2E6FF);
  border: 1px solid rgba(63,122,107,.25);
  cursor: help;
}
.ns-bc-energy-num { font-size: 20px; font-weight: 800; line-height: 1; color: #2F6B5A; }
.ns-bc-energy-label { font-size: 10px; color: #3F7A6B; margin-top: 2px; }
.ns-bc-body { display: flex; gap: 14px; align-items: flex-start; padding: 16px; }
.ns-bc-avatar {
  width: 60px; height: 60px; border-radius: 14px; flex-shrink: 0;
  background: linear-gradient(135deg, #FFD6E8, #FFE3C2);
  color: #7A4F6B; font-size: 24px; font-weight: 800;
  display: flex; align-items: center; justify-content: center; overflow: hidden;
}
.ns-bc-avatar img { width: 100%; height: 100%; object-fit: cover; }
.ns-bc-id { min-width: 0; flex: 1; padding-top: 2px; }
.ns-bc-name { font-size: 20px; font-weight: 800; color: #3D2E4A; }
.ns-bc-nick { font-size: 13px; color: #8B5FB0; font-weight: 600; margin-top: 2px; }
.ns-bc-pos { font-size: 13.5px; color: #7A6B82; margin-top: 3px; }
.ns-bc-titles { margin-top: 9px; display: flex; flex-wrap: wrap; gap: 6px; }
.ns-bc-tag {
  font-size: 11.5px; font-weight: 600;
  padding: 3px 10px; border-radius: 999px;
  background: #F1E6FF; color: #8B5FB0;
  border: 1px solid #E0D0FF;
}
.ns-bc-contact {
  border-top: 1px solid #F0E2F2;
  padding: 12px 16px 16px;
  display: flex; flex-direction: column; gap: 9px;
}
.ns-bc-line { display: flex; align-items: center; gap: 10px; font-size: 13.5px; color: #3D2E4A; }
.ns-bc-ic { width: 22px; text-align: center; font-size: 14px; opacity: .85; flex-shrink: 0; }
.ns-bc-val { flex: 1; min-width: 0; word-break: break-all; }
.ns-bc-line[hidden] { display: none; }
.ns-bc-locked { color: #A99CB0; font-size: 12.5px; }
.ns-bc-muted { color: #B3A8BA; font-size: 12.5px; }
.ns-bc-qr { flex-shrink: 0; align-self: center; display: flex; flex-direction: column; align-items: center; gap: 4px; }
.ns-bc-qr-img { width: 74px; height: 74px; border-radius: 10px; object-fit: contain; background: #fff; border: 1px solid rgba(108,92,231,.22); box-shadow: 0 3px 10px rgba(108,92,231,.12); }
.ns-bc-qr-tip { font-size: 10px; color: #7A6B82; }
/* 名片详情页底部二维码卡片：网址二维码 / 用户微信二维码 切换 */
.ns-qr-card { padding: 14px; }
.ns-qr-tabs { display: flex; gap: 8px; margin: 10px 0 12px; }
.ns-qr-tab { flex: 1; padding: 9px 0; border: 1px solid rgba(108,92,231,.32); background: #fff; color: #6C5CE7; border-radius: 8px; font-size: 13px; cursor: pointer; transition: background .15s, color .15s, border-color .15s; }
.ns-qr-tab.active { background: #6C5CE7; color: #fff; border-color: #6C5CE7; }
.ns-qr-body { display: flex; justify-content: center; }
.ns-qr-panel { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.ns-qr-img { width: 176px; height: 176px; border-radius: 12px; object-fit: contain; background: #fff; border: 1px solid rgba(108,92,231,.22); box-shadow: 0 4px 14px rgba(108,92,231,.15); padding: 8px; }
.ns-qr-tip { font-size: 12px; color: #7A6B82; }
.ns-qr-err { font-size: 12px; color: #e74c3c; padding: 18px 0; }

/* ===== 我的名片 · 三张隔离名片：三种马卡龙配色，便于区分 ===== */
/* 槽位 1：草莓马卡龙（粉） */
.ns-bizcard.slot-1 {
  background: linear-gradient(160deg, #FFFBFE 0%, #FFF1F6 100%);
  border-color: #F7D6E4;
  box-shadow: 0 6px 20px rgba(245,160,190,.22);
}
.ns-bizcard.slot-1 .ns-bc-header { background: linear-gradient(135deg, #FFD9E6 0%, #FFC2D8 100%); color: #9C3D63; }
.ns-bizcard.slot-1 .ns-bc-orgname { color: #9C3D63; }
.ns-bizcard.slot-1 .ns-bc-logo { background: rgba(255,255,255,.6); color: #C25E83; }
.ns-bizcard.slot-1 .ns-bc-energy { background: linear-gradient(135deg, #FFE3EF, #FFC9DD); border-color: rgba(196,80,120,.25); }
.ns-bizcard.slot-1 .ns-bc-energy-num { color: #C25E83; }
.ns-bizcard.slot-1 .ns-bc-energy-label { color: #D76A92; }
.ns-bizcard.slot-1 .ns-bc-avatar { background: linear-gradient(135deg, #FFE6F0, #FFD0E0); color: #C25E83; }
.ns-bizcard.slot-1 .ns-bc-nick { color: #D76A92; }
.ns-bizcard.slot-1 .ns-bc-tag { background: #FFE9F1; color: #C25E83; border-color: #FFD0E0; }

/* 槽位 2：抹茶马卡龙（绿） */
.ns-bizcard.slot-2 {
  background: linear-gradient(160deg, #FBFEFC 0%, #F1FBF4 100%);
  border-color: #D9F0E2;
  box-shadow: 0 6px 20px rgba(120,200,150,.20);
}
.ns-bizcard.slot-2 .ns-bc-header { background: linear-gradient(135deg, #D6F0DE 0%, #BCE8CC 100%); color: #3F7A55; }
.ns-bizcard.slot-2 .ns-bc-orgname { color: #3F7A55; }
.ns-bizcard.slot-2 .ns-bc-logo { background: rgba(255,255,255,.6); color: #4E8A66; }
.ns-bizcard.slot-2 .ns-bc-energy { background: linear-gradient(135deg, #D2EFDC, #B6E7C6); border-color: rgba(63,122,90,.25); }
.ns-bizcard.slot-2 .ns-bc-energy-num { color: #3F7A55; }
.ns-bizcard.slot-2 .ns-bc-energy-label { color: #4E8A66; }
.ns-bizcard.slot-2 .ns-bc-avatar { background: linear-gradient(135deg, #E4F5EA, #D2EFDD); color: #4E8A66; }
.ns-bizcard.slot-2 .ns-bc-nick { color: #4E8A66; }
.ns-bizcard.slot-2 .ns-bc-tag { background: #E4F5EA; color: #3F7A55; border-color: #C9EBD6; }

/* 槽位 3：香芋马卡龙（紫） */
.ns-bizcard.slot-3 {
  background: linear-gradient(160deg, #FBFAFE 0%, #F6F2FE 100%);
  border-color: #E6DBFB;
  box-shadow: 0 6px 20px rgba(160,140,230,.20);
}
.ns-bizcard.slot-3 .ns-bc-header { background: linear-gradient(135deg, #E6DBFB 0%, #D4C2F3 100%); color: #6A4F9C; }
.ns-bizcard.slot-3 .ns-bc-orgname { color: #6A4F9C; }
.ns-bizcard.slot-3 .ns-bc-logo { background: rgba(255,255,255,.6); color: #7A5FB0; }
.ns-bizcard.slot-3 .ns-bc-energy { background: linear-gradient(135deg, #E4D9FB, #D2C2F5); border-color: rgba(106,79,156,.25); }
.ns-bizcard.slot-3 .ns-bc-energy-num { color: #6A4F9C; }
.ns-bizcard.slot-3 .ns-bc-energy-label { color: #7A5FB0; }
.ns-bizcard.slot-3 .ns-bc-avatar { background: linear-gradient(135deg, #ECE3FB, #DED0F5); color: #7A5FB0; }
.ns-bizcard.slot-3 .ns-bc-nick { color: #7A5FB0; }
.ns-bizcard.slot-3 .ns-bc-tag { background: #EDE4FB; color: #6A4F9C; border-color: #D9C8F5; }

/* 编辑视图：当前名片色系标记 + 顶部分隔条，便于区分正在编辑哪张 */
.ns-slot-chip { margin-left: 8px; font-size: 11px; font-weight: 700; padding: 2px 9px; border-radius: 999px; vertical-align: middle; }
.ns-slot-chip.slot-1 { background: #FFE3EF; color: #C25E83; }
.ns-slot-chip.slot-2 { background: #E4F5EA; color: #3F7A55; }
.ns-slot-chip.slot-3 { background: #ECE3FB; color: #6A4F9C; }
.ns-pinfo.slot-1 { border-top: 3px solid #FFB3CC; }
.ns-pinfo.slot-2 { border-top: 3px solid #9BD9B0; }
.ns-pinfo.slot-3 { border-top: 3px solid #C3AEF2; }

.ns-info-card { padding: 16px; }
.ns-info-head { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.ns-info-avatar {
  width: 60px; height: 60px; border-radius: 18px; flex-shrink: 0;
  background: linear-gradient(135deg, var(--primary-light), var(--accent));
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 24px; font-weight: 800; overflow: hidden;
}
.ns-info-avatar img { width: 100%; height: 100%; object-fit: cover; }
.ns-info-main { min-width: 0; flex: 1; }
.ns-info-name { font-size: 18px; font-weight: 800; color: var(--text); }
.ns-info-sub { font-size: 12.5px; color: var(--text-muted); margin-top: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ns-info-rows { border-top: 1px solid var(--border); padding-top: 10px; }
.ns-info-row {
  display: flex; align-items: baseline; gap: 10px;
  padding: 6px 0; font-size: 13.5px;
}
.ns-info-row .ns-ir-k {
  width: 42px; flex-shrink: 0; color: var(--text-muted); font-size: 12.5px; font-weight: 600;
}
.ns-info-row .ns-ir-v { color: var(--text); flex: 1; min-width: 0; word-break: break-word; white-space: pre-wrap; }
/* 头衔 / 简介等多行内容的行：标签与内容顶部对齐 */
.ns-info-row.ns-row-block { align-items: flex-start; }
.ns-info-row.ns-row-block .ns-ir-k { padding-top: 7px; }

/* 头衔：可增减列表 */
.ns-titles-wrap { flex: 1; min-width: 0; }
.ns-title-item { display: flex; align-items: center; gap: 6px; margin-bottom: 6px; }
.ns-title-item:last-child { margin-bottom: 4px; }
.ns-title-item .ns-inline-input { flex: 1; min-width: 0; }
.ns-title-del {
  flex-shrink: 0; width: 26px; height: 26px; border-radius: 7px;
  border: none; background: #ffeaea; color: #ff4d4f; font-size: 16px; line-height: 1;
  cursor: pointer; transition: background .15s;
}
.ns-title-del:hover { background: #ffd5d5; }
.ns-add-title {
  margin-top: 2px; border: 1px dashed var(--border); background: transparent;
  color: var(--primary); padding: 6px 12px; border-radius: 8px; font-size: 13px;
  font-weight: 600; cursor: pointer; transition: background .15s, border-color .15s;
}
.ns-add-title:hover { background: rgba(108,92,231,.08); border-color: var(--primary); }

/* 2 行文本域（简介）：可纵向拉伸，与行内输入框视觉一致 */
.ns-textarea-2 {
  resize: vertical; min-height: 52px; line-height: 1.5; font-weight: 600;
  font-size: 13.5px; padding: 6px 8px; overflow: hidden;
}

/* ===== 我的名片 · 顶部可编辑个人资料卡 ===== */
.ns-pinfo .ns-info-head { margin-bottom: 4px; }
.ns-pinfo .ns-info-main { min-width: 0; flex: 1; }
/* 行内可编辑输入框：默认透明，聚焦高亮 */
.ns-inline-input {
  width: 100%;
  box-sizing: border-box;
  border: 1px solid transparent;
  border-radius: 8px;
  background: transparent;
  color: var(--text);
  font-family: inherit;
  outline: none;
  padding: 6px 8px;
  transition: background .15s, border-color .15s, box-shadow .15s;
}
.ns-inline-input::placeholder { color: var(--text-muted); }
.ns-inline-input:hover { background: var(--bg); }
.ns-inline-input:focus { background: #fff; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(108,92,231,.12); }
.ns-inline-input.invalid,
.ns-inline-input.invalid:focus { border-color: #ff4d4f !important; background: #fff; }
.ns-info-row .form-error {
  flex-basis: 100%;
  width: 100%;
  color: #ff4d4f;
  font-size: 12px;
  margin-top: 6px;
  padding-left: 64px;
  line-height: 1.4;
}
.ns-name-input { font-size: 17px; font-weight: 800; }
/* 联系方式编辑行：标签 + 输入框 + 隐私下拉 */
.ns-contact-card { padding: 14px 16px; }
.ns-ct-row { display: flex; align-items: center; gap: 8px; padding: 5px 0; }
.ns-ct-row .ns-ir-k { width: 42px; flex-shrink: 0; color: var(--text-muted); font-size: 12.5px; font-weight: 600; }
.ns-ct-row .ns-ir-input { flex: 1; min-width: 0; }
.ns-priv {
  flex: 0 0 auto; width: auto; min-width: 100px; padding: 6px 8px; box-sizing: border-box;
  border: 1px solid var(--border); border-radius: 8px; font-size: 12.5px;
  background: #fff; color: var(--text); outline: none; cursor: pointer;
}
.ns-priv:focus { border-color: var(--primary); }
.ns-pinfo .ns-info-sub .ns-inline-input { font-size: 13px; font-weight: 600; color: var(--text-muted); padding-top: 2px; padding-bottom: 2px; }
.ns-ir-input { font-weight: 600; font-size: 13.5px; padding: 5px 8px; }
/* 头像可点击上传 */
.ns-pinfo .ns-info-avatar { position: relative; cursor: pointer; }
.ns-pinfo .ns-info-avatar img { border-radius: 18px; }
.ns-avatar-cam {
  position: absolute; right: -2px; bottom: -2px;
  width: 24px; height: 24px; border-radius: 50%;
  background: rgba(0,0,0,.55); color: #fff; border: 2px solid #fff;
  display: flex; align-items: center; justify-content: center; font-size: 12px; line-height: 1;
}
.ns-avatar-cam:active { transform: scale(.92); }

.ns-photo-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.ns-photo-add {
  aspect-ratio: 1; border-radius: 12px;
  border: 1.5px dashed var(--primary-light);
  background: rgba(108,92,231,.05);
  color: var(--primary);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  font-size: 26px; font-weight: 700; cursor: pointer;
}
.ns-photo-add span { font-size: 12px; font-weight: 600; margin-top: 2px; }
.ns-photo-item {
  position: relative; aspect-ratio: 1; border-radius: 12px; overflow: hidden;
  border: 2px solid transparent; cursor: pointer; background: #f0f0f0;
}
.ns-photo-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ns-photo-item.sel { border-color: var(--primary); }
.ns-photo-flag {
  position: absolute; left: 0; bottom: 0; right: 0;
  font-size: 10px; font-weight: 700; color: #fff; text-align: center;
  background: var(--primary); padding: 2px 0; display: none;
}
.ns-photo-item.sel .ns-photo-flag { display: block; }
.ns-photo-del {
  position: absolute; right: 3px; top: 3px;
  width: 20px; height: 20px; border-radius: 50%;
  background: rgba(0,0,0,.5); color: #fff; border: none;
  font-size: 13px; line-height: 1; display: flex; align-items: center; justify-content: center;
}
.ns-photo-tip { font-size: 11.5px; color: var(--text-muted); margin-top: 10px; line-height: 1.5; }

/* ===== 参考图网格（AI 图生图）===== */
.ns-ref-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.ns-ref-add {
  aspect-ratio: 1; border-radius: 12px;
  border: 1.5px dashed var(--primary-light);
  background: rgba(108,92,231,.05);
  color: var(--primary);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  font-size: 26px; font-weight: 700; cursor: pointer;
}
.ns-ref-add span { font-size: 12px; font-weight: 600; margin-top: 2px; }
.ns-ref-item {
  position: relative; aspect-ratio: 1; border-radius: 12px; overflow: hidden;
  border: 2px solid var(--primary); cursor: default; background: #f0f0f0;
}
.ns-ref-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ns-ref-del {
  position: absolute; right: 3px; top: 3px;
  width: 20px; height: 20px; border-radius: 50%;
  background: rgba(0,0,0,.5); color: #fff; border: none;
  font-size: 13px; line-height: 1; display: flex; align-items: center; justify-content: center;
  cursor: pointer;
}

/* 表单标签内的小按钮（用资料生成提示词等） */
.ns-mini-btn {
  float: right;
  font-size: 11.5px; font-weight: 700; line-height: 1;
  color: var(--primary); background: rgba(108,92,231,.1);
  border: 1px solid var(--primary-light);
  border-radius: 999px; padding: 5px 10px;
  cursor: pointer; transition: background .15s;
}
.ns-mini-btn:active { background: rgba(108,92,231,.22); }

/* ===== 视频图文（富媒体块）编辑器 ===== */
.mm-tools { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.mm-add-btn {
  flex: 1 1 calc(50% - 8px); min-width: 120px;
  font-size: 13px; font-weight: 700; color: var(--primary);
  background: rgba(108,92,231,.08); border: 1px dashed var(--primary-light);
  border-radius: 10px; padding: 11px 8px; cursor: pointer; transition: background .15s, box-shadow .15s;
}
.mm-add-btn:active { background: rgba(108,92,231,.18); }
/* 图文名片（?type=image）不支持视频类块：置灰表示不可用，但仍可点击以弹出说明 */
.mm-add-btn.mm-add-btn--off {
  color: var(--text-muted);
  background: rgba(0,0,0,.04);
  border: 1px dashed var(--border);
  cursor: not-allowed;
}
.mm-add-btn.mm-add-btn--off:active { background: rgba(0,0,0,.04); }
.mm-block { padding: 12px; }
.mm-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.mm-type { font-size: 12.5px; font-weight: 700; color: var(--primary); background: rgba(108,92,231,.1); padding: 4px 10px; border-radius: 999px; }
.mm-ops { display: flex; gap: 6px; }
.mm-ops button {
  font-size: 12px; font-weight: 700; line-height: 1; padding: 6px 9px;
  border-radius: 8px; border: 1px solid var(--border); background: #fff; color: var(--text); cursor: pointer;
}
.mm-ops .mm-up, .mm-ops .mm-down { color: var(--primary); border-color: var(--primary-light); }
.mm-ops .mm-del { color: #e74c3c; border-color: rgba(231,76,60,.4); }
.mm-ops button:disabled { opacity: .35; cursor: not-allowed; }
.mm-title { margin-bottom: 10px; }
.mm-imgs { display: flex; flex-wrap: wrap; gap: 8px; }
.mm-img-item { position: relative; width: 84px; height: 84px; border-radius: 10px; overflow: hidden; border: 1px solid var(--border); }
.mm-img-item img { width: 100%; height: 100%; object-fit: cover; }
.mm-img-del { position: absolute; top: 2px; right: 2px; width: 18px; height: 18px; border-radius: 50%; background: rgba(0,0,0,.6); color: #fff; font-size: 12px; line-height: 18px; text-align: center; cursor: pointer; }
.mm-img-add { width: 84px; height: 84px; border-radius: 10px; border: 1px dashed var(--primary-light); background: rgba(108,92,231,.06); color: var(--primary); display: flex; flex-direction: column; align-items: center; justify-content: center; font-size: 22px; cursor: pointer; }
.mm-img-add span { font-size: 11px; font-weight: 600; }
.mm-video-wrap { display: flex; flex-direction: column; gap: 10px; }
.mm-video { width: 100%; max-height: 320px; border-radius: 10px; background: #000; }
.mm-vid-add { align-self: flex-start; font-size: 13px; }
/* ===== 视频列表块：编辑态条目 ===== */
.mm-vl-list { display: flex; flex-direction: column; gap: 10px; }
.mm-vl-item { border: 1px solid var(--border); border-radius: 10px; padding: 10px; background: #fbfbfd; }
.mm-vl-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; gap: 8px; }
.mm-vl-idx { font-size: 12px; font-weight: 700; color: var(--text-muted); }
.mm-vl-ops { display: flex; align-items: center; gap: 6px; }
.mm-vl-type { font-size: 12px; padding: 3px 6px; border-radius: 7px; border: 1px solid var(--border); background: #fff; color: var(--text); }
.mm-vl-del { font-size: 12px; padding: 3px 8px; border-radius: 7px; border: 1px solid rgba(231,76,60,.35); background: rgba(231,76,60,.06); color: #e74c3c; cursor: pointer; }
.mm-vl-body { display: flex; gap: 10px; align-items: flex-start; }
.mm-vl-main { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 8px; }
/* 封面：有图时 84×84 圆角缩略图 + 右上角删除；无图时是虚线「＋封面」框 */
.mm-vl-cover { position: relative; flex: 0 0 auto; width: 84px; height: 84px; border-radius: 10px; overflow: hidden; border: 1px dashed var(--primary-light); background: rgba(108,92,231,.06); color: var(--primary); display: flex; flex-direction: column; align-items: center; justify-content: center; font-size: 22px; cursor: pointer; }
.mm-vl-cover span { font-size: 11px; font-weight: 600; }
.mm-vl-cover.has-img { border-style: solid; border-color: var(--border); }
.mm-vl-cover img { width: 100%; height: 100%; object-fit: cover; }
.mm-vl-cover-del { position: absolute; top: 2px; right: 2px; width: 20px; height: 20px; border-radius: 50%; background: rgba(0,0,0,.6); color: #fff; font-size: 14px; line-height: 20px; text-align: center; cursor: pointer; }
.mm-vl-video { width: 100%; max-height: 180px; border-radius: 8px; background: #000; }
.mm-vl-btn { align-self: flex-start; display: inline-block; font-size: 13px; padding: 6px 12px; border-radius: 8px; border: 1px solid var(--border); background: #fff; color: var(--primary); font-weight: 600; cursor: pointer; }
.mm-vl-link { font-size: 13px; }
.mm-vl-add { margin-top: 10px; font-size: 13px; padding: 7px 14px; border-radius: 9px; border: 1px dashed var(--primary-light); background: rgba(108,92,231,.06); color: var(--primary); font-weight: 600; cursor: pointer; }
/* ===== 高级图文编辑器（富文本，contenteditable） ===== */
.mm-rich { border: 1px solid var(--border); border-radius: 10px; overflow: hidden; background: #fff; }
.mmr-bar { display: flex; flex-direction: column; gap: 6px; padding: 8px; background: rgba(108,92,231,.05); border-bottom: 1px solid var(--border); }
.mmr-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.mmr-btn {
  min-width: 34px; height: 32px; padding: 0 9px; font-size: 13px; font-weight: 700; line-height: 1;
  color: var(--text); background: #fff; border: 1px solid var(--border); border-radius: 8px; cursor: pointer;
}
.mmr-btn:active, .mmr-btn.on { color: #fff; background: var(--primary); border-color: var(--primary); }
.mmr-sel {
  height: 32px; padding: 0 6px; font-size: 13px; color: var(--text);
  background: #fff; border: 1px solid var(--border); border-radius: 8px;
}
.mmr-colors { display: flex; flex-wrap: wrap; gap: 6px; }
.mmr-color {
  width: 24px; height: 24px; padding: 0; border-radius: 50%; cursor: pointer;
  border: 2px solid #fff; box-shadow: 0 0 0 1px var(--border);
}
/* 图标按钮（对齐图标）/ AI 排版按钮 / 背景色色板 */
.mmr-btn.mmr-ico { min-width: 34px; padding: 0 8px; display: inline-flex; align-items: center; justify-content: center; }
.mmr-btn.mmr-ico svg { display: block; }
.mmr-btn.mmr-ai { color: #fff; background: linear-gradient(135deg, #6C5CE7, #8e44ad); border: 0; font-weight: 700; }
.mmr-btn.mmr-ai:active { filter: brightness(.95); }
.mmr-btn.mmr-ai:disabled { opacity: .6; cursor: default; }
.mmr-color.mmr-bg { border-radius: 6px; }
.mmr-editor {
  min-height: 120px; max-height: 420px; overflow-y: auto; padding: 10px 12px;
  font-size: 16px; line-height: 1.8; color: var(--text); outline: none; word-break: break-word;
}
.mmr-editor:empty::before { content: attr(data-ph); color: var(--text-muted); font-size: 13px; }
.mmr-editor img { max-width: 100%; height: auto; border-radius: 8px; display: block; margin: 6px 0; }
.mmr-editor p { font-size: 16px; line-height: 1.8; margin: 10px 0; }
/* 黑体（Heiti/SimHei 优先，移动端回退 PingFang/YaHei）+ 粗体 + 大/小标题字号 */
.mmr-editor h2 { font-family: "SimHei", "Heiti SC", "Microsoft YaHei", "PingFang SC", sans-serif; font-size: 28px; font-weight: 800; line-height: 1.4; margin: 14px 0 8px; }
.mmr-editor h3 { font-family: "SimHei", "Heiti SC", "Microsoft YaHei", "PingFang SC", sans-serif; font-size: 22px; font-weight: 800; line-height: 1.4; margin: 12px 0 6px; }
.mmr-editor ul, .mmr-editor ol { margin: 6px 0; padding-left: 22px; }
.mmr-editor ul { list-style: disc; }
.mmr-editor ol { list-style: decimal; }
.mmr-editor li { margin: 2px 0; }
.mmr-editor blockquote {
  margin: 6px 0; padding: 4px 10px; color: var(--text-light);
  border-left: 3px solid var(--primary-light); background: rgba(108,92,231,.05);
}
.mmr-editor a { color: var(--primary); text-decoration: underline; }
.mmr-src {
  display: none; width: 100%; min-height: 140px; padding: 10px 12px; border: 0; outline: none; resize: vertical;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12.5px; line-height: 1.6; color: var(--text); background: #fafafc;
}
.mm-rich.mmr-src-on .mmr-editor { display: none; }
.mm-rich.mmr-src-on .mmr-src { display: block; }
/* 新增 / 移动块的定位高亮 */
.mm-flash { animation: mm-flash 1.4s ease-out; }
@keyframes mm-flash {
  0% { box-shadow: 0 0 0 3px rgba(108,92,231,.5); }
  100% { box-shadow: 0 0 0 0 rgba(108,92,231,0); }
}
.mm-tip { font-size: 12px; color: var(--text-muted); margin: 6px 0 0; }

/* 对外展示：视频图文 */
.ds-media-block { margin-bottom: 14px; }
.ds-media-title { font-size: 14px; font-weight: 700; color: var(--text); margin-bottom: 8px; }
.ds-carousel-wrap { position: relative; }
.ds-carousel { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; gap: 0; -webkit-overflow-scrolling: touch; padding-bottom: 2px; position: relative; scroll-behavior: smooth; border-radius: 14px; }
.ds-carousel-cell { flex: 0 0 100%; width: 100%; border-radius: 14px; overflow: hidden; background: #f2f2f5; scroll-snap-align: center; box-shadow: 0 4px 14px rgba(108,92,231,.12); }
.ds-carousel-cell img { width: 100%; height: auto; display: block; }
.ds-carousel-dots { display: flex; justify-content: center; gap: 6px; margin-top: 8px; }
.ds-dot { width: 7px; height: 7px; border-radius: 50%; background: rgba(108,92,231,.28); transition: all .2s; cursor: pointer; }
.ds-dot.active { width: 18px; border-radius: 4px; background: var(--primary, #6C5CE7); }
.ds-media-imgs { display: flex; flex-direction: column; gap: 8px; }
.ds-media-img { width: 100%; height: auto; display: block; border-radius: 10px; background: #f2f2f5; }
.ds-video { width: 100%; max-height: 360px; border-radius: 10px; background: #000; }
/* 视频列表块：一行两列卡片（封面在上、名称在下，名称用黑色字体）
   封面按竖版 3:4 取高，卡片饱满且不至于过高 */
.ds-vlist { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.ds-vlist-card { display: block; text-decoration: none; color: inherit; border-radius: 12px; overflow: hidden; background: #fff; border: 1px solid var(--border); transition: transform .16s, box-shadow .16s; }
.ds-vlist-card:active { transform: scale(.985); }
a.ds-vlist-card:hover { box-shadow: 0 4px 14px rgba(108,92,231,.16); }
.ds-vlist-cover { display: block; width: 100%; aspect-ratio: 3 / 4; object-fit: cover; background: #ececf1; }
/* 封面缺失时的占位（播放角标），保持卡片高度一致 */
.ds-vlist-ph { display: flex; align-items: center; justify-content: center; font-size: 26px; color: #b9b9c6; }
/* 名称在图片下方，黑色字体（#000，不随主题变灰） */
.ds-vlist-name { padding: 7px 9px 9px; font-size: 13px; line-height: 1.35; color: #000; word-break: break-word; }
.ds-html { font-size: 16px; line-height: 1.8; color: var(--text); word-break: break-word; }
.ds-html img { max-width: 100%; border-radius: 8px; }
.ds-html a { color: var(--primary); }
/* 富文本编辑器能产出标题/列表/引用/表格，对外展示页必须配套样式，否则会挤成一坨 */
.ds-html p { font-size: 16px; line-height: 1.8; margin: 10px 0; }
.ds-html h1 { font-size: 30px; font-weight: 800; margin: 14px 0 8px; }
.ds-html h2 { font-family: "SimHei", "Heiti SC", "Microsoft YaHei", "PingFang SC", sans-serif; font-size: 28px; font-weight: 800; line-height: 1.4; margin: 14px 0 8px; }
.ds-html h3 { font-family: "SimHei", "Heiti SC", "Microsoft YaHei", "PingFang SC", sans-serif; font-size: 22px; font-weight: 800; line-height: 1.4; margin: 12px 0 6px; }
.ds-html h4, .ds-html h5, .ds-html h6 { font-size: 14.5px; font-weight: 800; margin: 8px 0 4px; }
.ds-html ul, .ds-html ol { margin: 6px 0; padding-left: 22px; }
.ds-html ul { list-style: disc; }
.ds-html ol { list-style: decimal; }
.ds-html li { margin: 2px 0; }
.ds-html blockquote {
  margin: 6px 0; padding: 4px 10px; color: var(--text-light);
  border-left: 3px solid var(--primary-light); background: rgba(108,92,231,.05);
}
.ds-html pre { margin: 6px 0; padding: 8px 10px; background: #f5f5f8; border-radius: 8px; overflow-x: auto; }
.ds-html code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 13px; }
.ds-html table { width: 100%; border-collapse: collapse; margin: 6px 0; }
.ds-html td, .ds-html th { border: 1px solid var(--border); padding: 5px 8px; }
.ds-html hr { border: 0; border-top: 1px solid var(--border); margin: 10px 0; }

/* ===== 资料与海报 · 公司 Logo 上传 ===== */
.ns-logo-wrap { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.ns-logo-prev { width: 56px; height: 56px; border-radius: 10px; object-fit: contain; background: rgba(108,92,231,.08); border: 1px solid rgba(108,92,231,.22); }
.ns-logo-del { background: rgba(231,76,60,.12) !important; color: #c0392b !important; border-color: rgba(231,76,60,.3) !important; }

/* ===== 资料与海报 · 已生成 AI 图片列表 ===== */
/* 头像海报：大图两列网格
   ⚠ 轨道必须写 minmax(0, 1fr)，不能写 1fr：`1fr` 自带 auto 最小值，会被
   「＋上传图片」格子的 aspect-ratio 撑大 → 第一列比第二列宽（实测 183px vs 131px）；
   宽列里 3:4 的图片更高，把下方「设为个人卡 / 删除」挤出卡片、被 overflow:hidden 裁掉
   （表现为左侧图片更大且没有按钮）。 */
.ns-ai-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.ns-ai-item { border: 1px solid var(--border, rgba(108,92,231,.18)); border-radius: 14px; overflow: hidden; background: var(--card, #fff); display: flex; flex-direction: column; }
/* 缩略图统一 3:4；min-height:0 让图片可被压缩，按钮栏 flex:0 0 auto 永不被压掉 */
.ns-ai-item > img.ns-ai-img { width: 100%; aspect-ratio: 3 / 4; height: auto; min-height: 0; flex: 0 1 auto; object-fit: cover; display: block; background: #f2f2f5; cursor: zoom-in; transition: transform .15s ease; }
.ns-ai-item > img.ns-ai-img:active { transform: scale(.985); }
.ns-ai-actions { display: flex; flex: 0 0 auto; }
.ns-ai-btn { flex: 1; border: none; background: rgba(108,92,231,.1); color: var(--primary, #6C5CE7); font-size: 12.5px; padding: 9px 4px; cursor: pointer; }
.ns-ai-btn + .ns-ai-btn { border-left: 1px solid var(--border, rgba(108,92,231,.18)); }
.ns-ai-btn:active { background: rgba(108,92,231,.2); }
.ns-ai-btn.ns-ai-del { background: rgba(231,76,60,.1); color: #c0392b; }
.ns-ai-btn.ns-ai-del:active { background: rgba(231,76,60,.2); }
/* 「＋ 上传图片」格子：排在个人卡列表最前，空列表时也可见
   宽度 100% 交给网格轨道（与右侧个人卡等宽）；aspect-ratio 仅在「空列表独占一行」时
   决定高度，有个人卡时由网格拉伸对齐到同一行卡片的高度（不再比右侧大）。 */
.ns-ai-add {
  width: 100%; height: 100%; aspect-ratio: 3 / 4; border-radius: 14px;
  border: 1.5px dashed var(--primary-light, #A29BFE);
  background: rgba(108,92,231,.05);
  color: var(--primary, #6C5CE7);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  font-size: 30px; font-weight: 700; line-height: 1; cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.ns-ai-add span { font-size: 12.5px; font-weight: 600; }
.ns-ai-add:active { background: rgba(108,92,231,.12); }
/* 空列表时的说明：跨两列，避免被挤进第二个格子 */
.ns-ai-empty { grid-column: 1 / -1; font-size: 13px; color: var(--text-muted); padding: 2px 0 4px; line-height: 1.6; }

/* 头像海报点击放大（lightbox） */
.ns-lightbox { position: fixed; inset: 0; z-index: 9999; background: rgba(0,0,0,.9); display: none; align-items: center; justify-content: center; padding: 20px; }
.ns-lightbox.show { display: flex; }
.ns-lightbox img { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 10px; box-shadow: 0 10px 40px rgba(0,0,0,.5); }
.ns-lightbox-close { position: absolute; top: 14px; right: 20px; color: #fff; font-size: 32px; line-height: 1; cursor: pointer; opacity: .85; user-select: none; }

/* 个人展示名片卡：公司 Logo 图片 */
.ns-bc-logo img { width: 100%; height: 100%; object-fit: cover; border-radius: 9px; }

/* ===== 个人展示页 · 个人海报板块 ===== */
.ns-pp-actions { display: flex; }
.ns-pp-btn { flex: 1; border: none; background: rgba(108,92,231,.1); color: var(--primary, #6C5CE7); font-size: 13px; font-weight: 700; padding: 10px; border-radius: 10px; cursor: pointer; transition: background .15s; }
.ns-pp-btn:active { background: rgba(108,92,231,.2); }
.ns-pp-btn-sm { flex: 1; font-size: 12px; padding: 8px 4px; border-radius: 9px; border: 1px solid rgba(108,92,231,.25); background: #fff; color: var(--primary, #6C5CE7); font-weight: 700; cursor: pointer; }
.ns-pp-btn-sm:active { background: rgba(108,92,231,.12); }
.ns-pp-btn-sm.ns-pp-edit { color: #7A6B82; border-color: var(--border, rgba(0,0,0,.12)); }
.ns-pp-feat { display: flex; gap: 12px; align-items: center; }
.ns-pp-feat-img { width: 96px; height: 128px; object-fit: cover; border-radius: 12px; background: #f2f2f5; box-shadow: 0 4px 14px rgba(108,92,231,.14); cursor: zoom-in; flex-shrink: 0; }
.ns-pp-feat-info { min-width: 0; flex: 1; }
.ns-pp-feat-title { font-size: 14px; font-weight: 700; color: var(--text); margin-bottom: 10px; }
.ns-pp-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.ns-pp-cell { border: 1px solid var(--border, rgba(108,92,231,.18)); border-radius: 14px; overflow: hidden; background: var(--card, #fff); display: flex; flex-direction: column; }
.ns-pp-cell.is-feat { border-color: var(--primary, #6C5CE7); box-shadow: 0 0 0 2px rgba(108,92,231,.25); }
.ns-pp-thumb { width: 100%; aspect-ratio: 3 / 4; height: auto; object-fit: cover; display: block; background: #f2f2f5; cursor: zoom-in; }
.ns-pp-cell-name { font-size: 12px; font-weight: 600; color: var(--text); padding: 6px 8px 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ns-pp-cell-ops { display: flex; gap: 6px; padding: 8px; }
/* 海报放大 lightbox 内编辑链接 */
.ns-poster-lb-edit { position: absolute; bottom: 18px; left: 50%; transform: translateX(-50%); color: #fff; font-size: 14px; font-weight: 700; text-decoration: none; background: rgba(108,92,231,.92); padding: 9px 20px; border-radius: 999px; box-shadow: 0 6px 20px rgba(0,0,0,.4); }

/* ============ 个人展示：个人卡栏目（与「个人海报」独立） ============ */
.ns-card-feat { position: relative; cursor: zoom-in; line-height: 0; }
.ns-card-feat-img { width: 100%; height: auto; display: block; }
.ns-card-feat-hint { position: absolute; left: 0; right: 0; bottom: 0; line-height: 1.4; text-align: center; font-size: 12px; color: #fff; background: linear-gradient(transparent, rgba(0,0,0,.6)); padding: 22px 8px 10px; pointer-events: none; }
.ns-card-lb-inner { display: flex; flex-direction: column; align-items: center; max-width: 96vw; max-height: 92vh; gap: 10px; }
.ns-card-lb-inner > img { max-width: 100%; max-height: 64vh; object-fit: contain; border-radius: 10px; box-shadow: 0 10px 40px rgba(0,0,0,.5); }
.ns-card-lb-bar { display: flex; gap: 10px; }
.ns-card-gallery { display: flex; gap: 8px; overflow-x: auto; max-width: 96vw; padding: 6px; background: rgba(255,255,255,.08); border-radius: 10px; }
.ns-card-gallery img { width: 84px; height: 112px; object-fit: cover; border-radius: 8px; border: 2px solid transparent; cursor: pointer; flex-shrink: 0; }
.ns-card-gallery img.is-sel { border-color: #6C5CE7; }

/* ============ 区块标题（与人脉中心其它区块统一） ============ */
.pf-section-title {
  font-size: 14px; font-weight: 800; color: var(--text);
  margin: 4px 2px 10px; display: flex; align-items: center; gap: 6px;
}
.pf-section-title .bar { width: 4px; height: 15px; background: var(--primary); border-radius: 3px; }

/* ============ 个人展示：我的产品（小程序商城式样，可切换排列） ============ */
.ns-prod-head { display: flex; align-items: center; justify-content: space-between; margin: 4px 2px 10px; }
.ns-prod-toggle {
  display: inline-flex; align-items: center; gap: 3px;
  padding: 5px 11px; font-size: 12px; font-weight: 700; line-height: 1;
  color: var(--primary); background: rgba(108, 92, 231, .08);
  border: 1px solid rgba(108, 92, 231, .22); border-radius: 999px;
  cursor: pointer; user-select: none; white-space: nowrap;
}
.ns-prod-toggle:active { background: rgba(108, 92, 231, .16); }

/* 容器：商品卡（一行二个）/ 列表（一行一个） */
.ns-prod-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.ns-prod-list { display: flex; flex-direction: column; gap: 10px; }

/* 商品卡（小程序商城式样） */
.ns-prod-card {
  background: #fff; border-radius: 12px; overflow: hidden;
  box-shadow: 0 1px 6px rgba(0, 0, 0, .06);
  display: flex; flex-direction: column;
}
/* 列表模式：左图右文 */
.ns-prod-list .ns-prod-card { flex-direction: row; }

.ns-prod-img { width: 100%; aspect-ratio: 1 / 1; height: auto; object-fit: cover; display: block; background: #f2f3f5; }
.ns-prod-img-empty { display: flex; align-items: center; justify-content: center; font-size: 30px; color: #c8c9cc; }
.ns-prod-list .ns-prod-card .ns-prod-img { width: 96px; height: 96px; flex: 0 0 96px; aspect-ratio: auto; }

.ns-prod-body { padding: 8px 10px 10px; display: flex; flex-direction: column; flex: 1; min-width: 0; }
.ns-prod-row { display: flex; align-items: baseline; gap: 4px; margin-top: 4px; line-height: 1.4; }
.ns-prod-label { flex: none; font-size: 12px; font-weight: 700; color: var(--primary); white-space: nowrap; }
.ns-prod-row .ns-prod-name { -webkit-line-clamp: 2; }
.ns-prod-row .ns-prod-desc { -webkit-line-clamp: 3; }
.ns-prod-name {
  font-size: 13.5px; font-weight: 700; color: var(--text);
  line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2;
  -webkit-box-orient: vertical; overflow: hidden;
}
.ns-prod-desc {
  font-size: 11.5px; color: var(--text-light); line-height: 1.45; margin-top: 4px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.ns-prod-list .ns-prod-desc { -webkit-line-clamp: 3; }
.ns-prod-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: auto; padding-top: 8px; }
.ns-prod-price { color: #ff4d4f; font-weight: 800; font-size: 15px; white-space: nowrap; }
.ns-prod-link {
  display: inline-flex; align-items: center; padding: 5px 12px;
  font-size: 12px; font-weight: 700; color: #fff; text-decoration: none;
  background: var(--primary); border-radius: 999px; white-space: nowrap;
}
.ns-prod-link:active { opacity: .85; }

/* ===== AI 排版预览弹窗 ===== */
.mm-ai-overlay {
  position: fixed; inset: 0; z-index: 9999; display: flex; align-items: center; justify-content: center;
  background: rgba(0, 0, 0, .55); padding: 16px;
}
.mm-ai-modal {
  width: 100%; max-width: 520px; max-height: 86vh; display: flex; flex-direction: column; overflow: hidden;
  background: var(--card-bg, #fff); border-radius: 14px; box-shadow: 0 12px 40px rgba(0, 0, 0, .3);
}
.mm-ai-head {
  display: flex; align-items: center; justify-content: space-between; padding: 12px 16px;
  border-bottom: 1px solid var(--border, #eee); font-size: 15px; font-weight: 700; color: var(--text, #222);
}
.mm-ai-close { border: none; background: transparent; font-size: 22px; line-height: 1; cursor: pointer; color: var(--text-muted, #888); }
.mm-ai-body { padding: 16px; overflow-y: auto; max-height: 60vh; background: var(--card-bg, #fff); }
.mm-ai-loading, .mm-ai-error { padding: 30px 10px; text-align: center; font-size: 14px; color: var(--text-muted, #888); }
.mm-ai-error { color: #e74c3c; }
.mm-ai-foot { display: flex; gap: 10px; padding: 12px 16px; border-top: 1px solid var(--border, #eee); }
.mm-ai-foot button { flex: 1; padding: 11px 0; border: none; border-radius: 10px; font-size: 15px; font-weight: 700; cursor: pointer; }
.mm-ai-again { background: var(--bg-soft, #f0f0f3); color: var(--text, #333); }
.mm-ai-use { background: var(--primary, #6C5CE7); color: #fff; }
.mm-ai-foot button:disabled { opacity: .5; cursor: default; }

/* AI 创作需求输入 / 导入代码 共用的输入弹窗 */
.mm-imp-body { padding: 16px; }
.mm-imp-tip { font-size: 12px; line-height: 1.6; color: var(--text-muted, #888); margin: 0 0 10px; }
.mm-imp-ta {
  width: 100%; box-sizing: border-box; min-height: 150px; resize: vertical; outline: none;
  border: 1px solid var(--border, #e5e5e5); border-radius: 10px; padding: 10px 12px;
  font-size: 13px; line-height: 1.6; color: var(--text, #222); background: var(--bg-soft, #f6f6f8);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
}
.mm-imp-ta:focus { border-color: var(--primary, #6C5CE7); }
.mm-imp-confirm { background: var(--primary, #6C5CE7); color: #fff; }
.mm-imp-cancel { background: var(--bg-soft, #f0f0f3); color: var(--text, #333); }


/* ===== AI 排版弹窗：版式列表 / 源码切换 / 保存式样（2026-10）===== */
.mm-ai-head { gap: 8px; }
.mm-ai-head > span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mm-ai-srcbtn {
  flex: 0 0 auto; padding: 5px 11px; border-radius: 16px; cursor: pointer; font-size: 12px; font-weight: 700;
  background: #F5F6FA; color: #5D6472; border: none; transition: transform .12s;
}
.mm-ai-srcbtn:active { transform: scale(.96); }
.mm-ai-styles { padding: 10px 16px; border-bottom: 1px solid var(--border, #eee); background: #FBFBFE; }
.mm-ai-styles-t { font-size: 12px; font-weight: 700; color: var(--text-muted, #888); margin-bottom: 8px; }
.mm-ai-style-scroll {
  display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px;
  scroll-snap-type: x proximity; -webkit-overflow-scrolling: touch;
}
.mm-ai-style-scroll::-webkit-scrollbar { height: 4px; }
.mm-ai-style-scroll::-webkit-scrollbar-thumb { background: #DCDCE6; border-radius: 2px; }
.mm-ai-style {
  flex: 0 0 auto; scroll-snap-align: start; display: flex; align-items: center; gap: 7px;
  max-width: 200px; padding: 7px 11px; cursor: pointer; text-align: left;
  background: #fff; border: 1.5px solid #EEEFF5; border-radius: 12px; transition: all .15s;
}
.mm-ai-style:active { transform: scale(.96); }
.mm-ai-style.on {
  border-color: var(--primary, #6C5CE7);
  background: linear-gradient(135deg, #F6F4FF, #EFEBFF);
  box-shadow: 0 4px 14px rgba(108, 92, 231, .18);
}
.mm-ai-style-sw { flex: 0 0 auto; width: 20px; height: 20px; border-radius: 7px; box-shadow: inset 0 0 0 1px rgba(0,0,0,.06); }
.mm-ai-style-tx { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.mm-ai-style-tx b { font-size: 13px; font-weight: 700; color: var(--text, #222); white-space: nowrap; }
.mm-ai-style-tx i { font-size: 11px; font-style: normal; color: var(--text-muted, #999); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mm-ai-styles-empty { font-size: 12px; line-height: 1.6; color: var(--text-muted, #888); }
.mm-ai-src {
  margin: 0; max-height: 52vh; overflow: auto; padding: 12px; border-radius: 10px;
  background: #1E1E28; color: #E4E4EE; font-size: 12px; line-height: 1.6;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  white-space: pre-wrap; word-break: break-word;
}
.mm-ai-save { background: #F5F6FA; color: #5D6472; }

/* ===== 编辑页底部「我的排版式样」=====
   视觉基线（铁律 S）：淡彩渐变底 + 大圆角 + 极淡彩描边 + 分层柔和阴影，不用 1px 硬边框堆叠 */
.mbe-preset-shelf { margin-top: 18px; }
.mbe-preset-title {
  display: flex; align-items: baseline; flex-wrap: wrap; gap: 8px;
  font-size: 14px; font-weight: 800; color: var(--text, #222); margin-bottom: 9px;
}
.mbe-preset-tip { font-size: 11.5px; font-weight: 400; color: var(--text-muted, #999); }
.mbe-preset-scroll { display: flex; gap: 10px; overflow-x: auto; padding: 2px 2px 10px; -webkit-overflow-scrolling: touch; }
.mbe-preset-scroll::-webkit-scrollbar { height: 5px; }
.mbe-preset-scroll::-webkit-scrollbar-thumb { background: #E3E4EE; border-radius: 3px; }
.mbe-preset-card {
  flex: 0 0 140px; overflow: hidden; display: flex; flex-direction: column;
  border-radius: 16px; border: 1px solid rgba(108, 92, 231, .10);
  background: linear-gradient(160deg, #FBFAFF, #F3F1FF);
  box-shadow: 0 2px 8px rgba(108, 92, 231, .06), 0 8px 22px rgba(17, 24, 39, .05);
}
.mbe-preset-thumb {
  height: 108px; overflow: hidden; padding: 6px; background: #fff; font-size: 9px; line-height: 1.4;
  transform: scale(.5); transform-origin: top left; width: 200%; pointer-events: none;
}
.mbe-preset-meta { display: flex; align-items: center; gap: 6px; padding: 8px 9px; border-top: 1px solid rgba(108, 92, 231, .08); }
.mbe-preset-name { flex: 1; min-width: 0; font-size: 12px; font-weight: 700; color: var(--text, #333); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mbe-preset-ops { flex: 0 0 auto; display: flex; gap: 5px; }
.mbe-preset-use {
  padding: 4px 9px; border-radius: 14px; border: none; cursor: pointer; font-size: 11.5px; font-weight: 700;
  background: linear-gradient(135deg, #7C6BF0, #6C5CE7 58%, #5A4BD1); color: #fff;
  box-shadow: 0 3px 10px rgba(108, 92, 231, .28);
}
.mbe-preset-use:active { transform: scale(.96); }
.mbe-preset-del { padding: 4px 7px; border-radius: 14px; border: none; cursor: pointer; font-size: 12px; background: #fff; color: #DC2626; }

/* AI 排版弹窗：未排版的初始引导 + 换风格提示 + 错误自助提示（2026-10-07） */
.mm-ai-idle { padding: 26px 16px; text-align: center; }
.mm-ai-idle-t { font-size: 15px; font-weight: 600; color: var(--text, #2c3042); margin-bottom: 8px; }
.mm-ai-idle-s { font-size: 13px; color: var(--text-muted, #8b90a3); line-height: 1.7; }
.mm-ai-tip { padding: 22px 16px; text-align: center; font-size: 13px; color: #5D6472; line-height: 1.7; }
.mm-ai-errtip { margin-top: 12px; padding: 10px 12px; border-radius: 12px;
  background: #FFF7ED; color: #9A6212; font-size: 12.5px; line-height: 1.7; text-align: left; }
/* 「开始排版」是主操作，用主色渐变（铁律 S）；排过一次后由 JS 换成「再次排版」但仍保持主色 */
.mm-ai-foot .mm-ai-again { background: linear-gradient(135deg, #7C6BF0, #6C5CE7 58%, #5A4BD1);
  color: #fff; border: none; box-shadow: 0 4px 14px rgba(108, 92, 231, .28); }
/* 禁用态：去饱和 + 降透明，一眼看出点不动（截图里「使用」紫色太像可点） */
.mm-ai-foot .mm-ai-again:disabled { background: #DFDDF7; color: #fff; box-shadow: none; }
.mm-ai-foot .mm-ai-save:disabled, .mm-ai-foot .mm-ai-use:disabled {
  opacity: .45; filter: grayscale(.7); box-shadow: none; cursor: not-allowed; }
