/* 妙贴 DEMO · 全局样式 */
:root {
  --accent: #ea580c;
  --accent-soft: #ffedd5;
  --accent-deep: #c2410c;
  --text: #1f2937;
  --muted: #6b7280;
  --line: #ece7e1;
  --bg: #faf9f7;
  --card: #ffffff;
  --radius: 14px;
  /* P2 语义色（soft 为对应浅底色） */
  --ok: #15803d; --ok-soft: #dcfce7;
  --warn: #b45309; --warn-soft: #fef3c7;
  --danger: #b91c1c; --danger-soft: #fef2f2;
  --info: #1d4ed8; --info-soft: #eff6ff;
  /* P2 字号阶梯 */
  --fs-xs: 12px; --fs-sm: 13px; --fs-md: 14px; --fs-lg: 16px; --fs-xl: 20px;
  /* P2 间距阶梯 */
  --sp-1: 4px; --sp-2: 8px; --sp-3: 12px; --sp-4: 16px; --sp-5: 24px;
  /* P2 阴影：卡片浅阴影 / 浮层深阴影 */
  --shadow-1: 0 10px 28px rgba(31, 41, 55, 0.09);
  --shadow-2: 0 12px 32px rgba(31, 41, 55, 0.14);
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  font-family: "PingFang SC", "Microsoft YaHei", "Segoe UI", system-ui, sans-serif;
  background: var(--bg); color: var(--text); line-height: 1.6;
}
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
.wrap { max-width: 1280px; margin: 0 auto; padding: 0 24px; }

/* ---------- 头部 ---------- */
#mt-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, 0.92); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.hrow { display: flex; align-items: center; gap: 14px; height: 60px; }
.logo { font-size: 22px; font-weight: 800; letter-spacing: 1px; display: flex; align-items: baseline; gap: 6px; }
.logo i { width: 10px; height: 10px; border-radius: 3px; background: var(--accent); display: inline-block; transform: rotate(45deg) translateY(-1px); }
.logo span { font-size: 11px; font-weight: 400; color: var(--muted); letter-spacing: 0; }
.logo-mark { width: 26px; height: 26px; display: block; align-self: center; flex: none; }
.demo { font-style: normal; font-size: 11px; color: #92400e; background: #fef3c7; border: 1px solid #fde68a; padding: 1px 8px; border-radius: 99px; }
#mt-header nav { display: flex; gap: 4px; margin-left: 10px; }
#mt-header nav a { padding: 6px 14px; border-radius: 99px; font-size: 15px; color: var(--muted); }
#mt-header nav a:hover { background: #f4f1ec; color: var(--text); }
#mt-header nav a.on { background: var(--text); color: #fff; }
.hright { margin-left: auto; display: flex; align-items: center; gap: 10px; }

/* 「我的」下拉（P1 顶栏账户簇） */
.nav-dropdown { position: relative; }
.nav-me-btn { border: 1px solid var(--line); background: #fff; border-radius: 10px; padding: 7px 14px; font-size: 13.5px; color: var(--text); white-space: nowrap; }
.nav-me-btn:hover { background: #f4f1ec; }
.nav-dropdown.open .nav-me-btn { border-color: var(--accent); color: var(--accent); }
.nav-menu { display: none; position: absolute; right: 0; top: calc(100% + 8px); min-width: 208px; background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-2); padding: 6px; z-index: 60; }
.nav-dropdown.open .nav-menu { display: block; }
.nav-menu a { display: block; padding: 8px 12px; border-radius: 8px; font-size: 13.5px; color: var(--text); }
.nav-menu a:hover { background: #f4f1ec; color: var(--accent); }
.nav-menu hr { border: 0; border-top: 1px dashed var(--line); margin: 5px 6px; }
.nav-group { display: block; font-size: 11px; color: var(--muted); padding: 4px 12px 2px; }
.badge { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; padding: 3px 10px; border-radius: 99px; background: #f4f1ec; color: var(--muted); white-space: nowrap; }
.badge.model { background: #f4f1ec; }
.badge.model i { width: 8px; height: 8px; border-radius: 99px; display: inline-block; }
.badge.member { background: #fff7ed; color: var(--accent-deep); border: 1px solid #fed7aa; }

/* ---------- 按钮 ---------- */
.btn { border: 1px solid var(--line); background: #fff; border-radius: 10px; padding: 8px 16px; font-size: 14px; color: var(--text); transition: 0.15s; white-space: nowrap; }
.btn:hover { border-color: #d8d0c6; background: #fdfcfa; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn.primary:hover { background: #d94f08; }
.btn.ghost { background: transparent; }
.btn.sm { padding: 5px 12px; font-size: 13px; border-radius: 8px; }
.btn.big { width: 100%; padding: 12px; font-size: 15px; margin-top: 8px; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }

/* ---------- 首页 hero + 筛选 ---------- */
.hero { padding: 34px 0 6px; }
.hero h1 { font-size: 26px; font-weight: 800; }
.hero h1 b { color: var(--accent); }
.hero p { color: var(--muted); margin-top: 4px; font-size: 14px; }
.searchrow { display: flex; gap: 12px; margin: 18px 0 6px; align-items: center; }
.search { flex: 1; max-width: 460px; display: flex; align-items: center; background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 0 14px; height: 42px; }
.search input { border: 0; outline: 0; flex: 1; font-size: 14px; background: transparent; }
.seg { display: flex; background: #fff; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.seg button { border: 0; background: transparent; padding: 8px 16px; font-size: 13px; color: var(--muted); }
.seg button.on { background: var(--text); color: #fff; }
.chips { display: flex; gap: 8px; overflow-x: auto; padding: 10px 0 4px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chip { flex-shrink: 0; padding: 5px 14px; border-radius: 99px; border: 1px solid var(--line); background: #fff; font-size: 13px; color: var(--muted); }
.chip small { opacity: 0.6; font-size: 11px; }
.chip.on { background: var(--accent); border-color: var(--accent); color: #fff; }
.chip.on small { opacity: 0.85; }
.chip-label { flex-shrink: 0; font-size: 12px; color: var(--muted); padding: 7px 2px 7px 0; }

/* ---------- 瀑布流卡片 ---------- */
.grid { columns: 4 240px; column-gap: 16px; margin: 14px 0 40px; }
.card {
  break-inside: avoid; margin-bottom: 16px; background: var(--card);
  border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
  cursor: pointer; transition: 0.18s; display: block;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow-1); }
.card img { width: 100%; display: block; }
.card-body { padding: 12px 14px 13px; }
.card-title { font-size: 15px; font-weight: 700; display: flex; align-items: center; gap: 8px; }
.card-title .new { font-size: 10px; color: #fff; background: var(--accent); border-radius: 4px; padding: 1px 5px; flex-shrink: 0; }
.card-title .new.hot { background: #f59e0b; }
.card-desc { font-size: 12.5px; color: var(--muted); margin-top: 3px; display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; }
.card-meta { display: flex; align-items: center; gap: 8px; margin-top: 9px; flex-wrap: wrap; }
.card-stats { margin-left: auto; font-size: 12px; color: var(--muted); display: flex; gap: 10px; white-space: nowrap; }
.empty { text-align: center; color: var(--muted); padding: 60px 0; }

/* ---------- 详情页 ---------- */
.freebar { background: #fffbeb; border-bottom: 1px solid #fde68a; color: #92400e; font-size: 13px; }
.freebar .wrap { display: flex; align-items: center; gap: 10px; height: 38px; }
.freebar a, .freebar button { color: var(--accent-deep); font-weight: 600; background: none; border: 0; font-size: 13px; text-decoration: underline; }
.detail { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 28px; padding: 26px 0 40px; align-items: start; }
@media (max-width: 900px) {
  .detail { grid-template-columns: 1fr; }
  .grid { columns: 2 200px; }
  .searchrow { flex-wrap: wrap; }
  .search { max-width: none; }
}
.dgallery img.main { width: 100%; border-radius: var(--radius); border: 1px solid var(--line); display: block; }
.thumbs { display: flex; gap: 10px; margin-top: 10px; }
.thumbs img { width: 84px; border-radius: 10px; border: 2px solid transparent; cursor: pointer; }
.thumbs img.on { border-color: var(--accent); }

.dpanel h2 { font-size: 21px; font-weight: 800; line-height: 1.35; }
.dpanel .badges { display: flex; gap: 8px; margin-top: 10px; flex-wrap: wrap; }
.dpanel .desc { color: var(--muted); font-size: 14px; margin-top: 10px; }
.dstats { display: flex; gap: 16px; color: var(--muted); font-size: 13px; margin-top: 12px; }
.dstats b { color: var(--text); }
.dactions { display: flex; gap: 10px; margin-top: 14px; flex-wrap: wrap; }
.dauthor { font-size: 12.5px; color: var(--muted); margin-top: 14px; }

.box { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; margin-top: 18px; }
.box h4 { font-size: 14px; margin-bottom: 10px; display: flex; align-items: center; gap: 8px; }
.box h4 .hint { font-weight: 400; font-size: 12px; color: var(--muted); }
.vrows .vrow { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.vrows label { width: 84px; font-size: 13px; color: var(--muted); flex-shrink: 0; }
.vrows select, .vrows input { flex: 1; height: 36px; border: 1px solid var(--line); border-radius: 9px; padding: 0 10px; font-size: 14px; background: #fff; outline-color: var(--accent); }
.preview { background: #fbfaf8; border: 1px dashed #ded6cb; border-radius: 10px; padding: 12px 14px; font-size: 13.5px; line-height: 1.9; min-height: 66px; word-break: break-all; }
.preview .vhl, .ptext .vhl { background: var(--accent-soft); color: var(--accent-deep); border-radius: 5px; padding: 1px 5px; font-weight: 700; font-style: normal; }
.ptext { white-space: pre-wrap; }
.copyrow { display: flex; gap: 10px; margin-top: 12px; align-items: center; }
.copyrow .hint { font-size: 12px; color: var(--muted); }

.versions .vitem { display: flex; gap: 10px; font-size: 13px; padding: 7px 0; border-bottom: 1px dashed var(--line); }
.versions .vitem:last-child { border-bottom: 0; }
.versions .vnum { color: var(--accent); font-weight: 700; flex-shrink: 0; width: 42px; }
.versions .vdate { color: var(--muted); font-size: 12px; margin-left: auto; flex-shrink: 0; }

.case { display: flex; gap: 12px; align-items: center; padding: 8px 0; border-bottom: 1px dashed var(--line); }
.case:last-child { border-bottom: 0; }
.case img { width: 58px; height: 58px; object-fit: cover; border-radius: 9px; }
.case .cm { font-size: 13.5px; font-weight: 600; }
.case .cp { font-size: 12px; color: var(--muted); }

.tabs { display: flex; gap: 4px; margin-bottom: 14px; background: #f4f1ec; padding: 4px; border-radius: 11px; width: fit-content; }
.tabs button { border: 0; background: transparent; padding: 7px 18px; border-radius: 8px; font-size: 13.5px; color: var(--muted); }
.tabs button.on { background: #fff; color: var(--text); font-weight: 600; box-shadow: 0 1px 4px rgba(0,0,0,0.06); }

/* 评论 */
.comment { display: flex; gap: 12px; padding: 12px 0; border-bottom: 1px dashed var(--line); }
.comment:last-child { border-bottom: 0; }
.avatar { width: 36px; height: 36px; border-radius: 99px; background: var(--accent-soft); color: var(--accent-deep); display: flex; align-items: center; justify-content: center; font-weight: 700; flex-shrink: 0; }
.comment .cuser { font-size: 13px; font-weight: 600; }
.comment .cuser span { font-weight: 400; color: var(--muted); font-size: 12px; margin-left: 8px; }
.comment .ctext { font-size: 13.5px; margin-top: 2px; }
/* 详情页改版 v0.6：作者卡片 / 评论独立卡 */
.authorbox { display: flex; align-items: center; gap: 12px; background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px; margin-top: 14px; }
.abox-id { display: flex; gap: 10px; align-items: center; flex: 1; min-width: 0; }
.abox-id:hover b { color: var(--accent); }
.abox-info { display: flex; flex-direction: column; font-size: 12px; color: var(--muted); line-height: 1.5; }
.abox-info b { font-size: 14px; color: var(--text); }
.followbig { min-width: 96px; }
.comment-composer textarea { width: 100%; min-height: 84px; border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; font-size: 13.5px; font-family: inherit; resize: vertical; outline-color: var(--accent); }
.crow { display: flex; align-items: center; gap: 8px; margin-top: 8px; }
.cform { display: flex; gap: 10px; margin-top: 6px; }

/* ---------- 设置页 ---------- */
.set-grid { display: grid; grid-template-columns: 210px minmax(0, 1fr); gap: 20px; padding: 20px 0 40px; align-items: start; }
#set-nav { display: flex; flex-direction: column; gap: 2px; position: sticky; top: 76px; }
#set-nav button { text-align: left; border: 0; background: none; padding: 9px 12px; border-radius: 9px; font-size: 13.5px; cursor: pointer; color: var(--text); }
#set-nav button:hover { background: #f4f1ec; }
#set-nav button.on { background: var(--accent-soft); color: var(--accent-deep); font-weight: 700; }
#set-nav hr { border: 0; border-top: 1px dashed var(--line); margin: 5px 0; }
@media (max-width: 900px) { .set-grid { grid-template-columns: 1fr; } #set-nav { position: static; flex-direction: row; flex-wrap: wrap; } }
/* 设置页/后台共用卡片（settings.js 的 .acard 此前只在 admin-pro 内联定义） */
.acard { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; margin: 12px 0; }
.cform textarea { flex: 1; border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; font-size: 13.5px; font-family: inherit; resize: vertical; min-height: 42px; outline-color: var(--accent); }

/* ---------- 表单（投稿） ---------- */
.formwrap { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 28px; padding: 26px 0 40px; align-items: start; }
@media (max-width: 900px) { .formwrap { grid-template-columns: 1fr; } }
.field { margin-bottom: 16px; }
.field > label { display: block; font-size: 13.5px; font-weight: 600; margin-bottom: 6px; }
.field > label small { font-weight: 400; color: var(--muted); margin-left: 6px; }
.field input[type=text], .field input[type=date], .field textarea, .field select {
  width: 100%; border: 1px solid var(--line); border-radius: 10px; padding: 9px 12px;
  font-size: 14px; font-family: inherit; background: #fff; outline-color: var(--accent);
}
.field input:disabled { background: #f9fafb; color: #9ca3af; }
.field textarea { resize: vertical; line-height: 1.8; }
.varb { border: 1px dashed #ded6cb; border-radius: 10px; padding: 12px; }
.varb .vrow { display: flex; gap: 8px; margin-bottom: 8px; align-items: center; }
.varb input { flex: 1; min-width: 0; border: 1px solid var(--line); border-radius: 8px; padding: 6px 9px; font-size: 13px; }
.varb .del { border: 0; background: none; color: var(--muted); font-size: 16px; }
.insert-tip { font-size: 12px; color: var(--muted); margin-top: 4px; }
.insert-tip a { color: var(--accent); }

/* ---------- 我的 ---------- */
.me-grid { display: grid; grid-template-columns: 320px 1fr; gap: 24px; padding: 26px 0 40px; align-items: start; }
@media (max-width: 900px) { .me-grid { grid-template-columns: 1fr; } }
.me-card { text-align: center; padding: 26px 20px; }
.me-avatar { width: 64px; height: 64px; border-radius: 99px; background: var(--accent-soft); color: var(--accent-deep); font-size: 26px; font-weight: 800; display: flex; align-items: center; justify-content: center; margin: 0 auto 10px; }
.me-stats { display: flex; justify-content: space-around; margin-top: 16px; padding-top: 14px; border-top: 1px dashed var(--line); }
.me-stats b { display: block; font-size: 18px; }
.me-stats span { font-size: 12px; color: var(--muted); }
.mine-grid { columns: 3 200px; column-gap: 14px; }
.mine-grid .card { margin-bottom: 14px; }
.danger { color: var(--danger); background: var(--danger-soft); border: 1px solid #fecaca; }

/* ---------- 付费墙 / toast ---------- */
#mt-paywall { position: fixed; inset: 0; background: rgba(31, 41, 55, 0.45); backdrop-filter: blur(3px); z-index: 100; display: flex; align-items: center; justify-content: center; padding: 20px; }
#mt-modal { position: fixed; inset: 0; background: rgba(31, 41, 55, 0.45); backdrop-filter: blur(3px); z-index: 110; display: flex; align-items: center; justify-content: center; padding: 20px; }
.pay-card { background: #fff; border-radius: 18px; padding: 30px 30px 24px; max-width: 400px; width: 100%; text-align: center; box-shadow: var(--shadow-2); }
.pay-tag { display: inline-block; background: var(--accent-soft); color: var(--accent-deep); font-size: 13px; font-weight: 700; padding: 3px 14px; border-radius: 99px; }
.pay-card h3 { font-size: 20px; margin: 12px 0 6px; }
.pay-card > p { font-size: 13.5px; color: var(--muted); }
.pay-card ul { list-style: none; text-align: left; margin: 16px auto 4px; max-width: 260px; }
.pay-card li { font-size: 13.5px; padding: 5px 0; color: var(--text); }
.pay-card li::before { content: "✓"; color: var(--accent); font-weight: 800; margin-right: 8px; }
.pay-price { font-size: 34px; font-weight: 800; color: var(--accent); margin: 6px 0 10px; }
.pay-price span { font-size: 14px; color: var(--muted); font-weight: 400; }
#mt-toast { position: fixed; left: 50%; bottom: 34px; transform: translateX(-50%) translateY(20px); background: var(--text); color: #fff; font-size: 13.5px; padding: 10px 20px; border-radius: 99px; opacity: 0; pointer-events: none; transition: 0.25s; z-index: 120; }
#mt-toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
#mt-toast.err { background: var(--danger); }

/* ---------- 页脚 ---------- */
#mt-footer { border-top: 1px solid var(--line); padding: 22px 24px 30px; text-align: center; color: var(--muted); font-size: 12.5px; }
#mt-footer a { color: var(--accent); }

.section-title { font-size: 17px; font-weight: 800; margin: 26px 0 4px; }
.section-sub { font-size: 13px; color: var(--muted); margin-bottom: 6px; }

/* ---------- v0.2 新增 ---------- */
/* AI 状态点 */
.aidot { font-size: 16px; cursor: help; opacity: 0.35; }
.aidot.ok { opacity: 1; }
.aidot.off { opacity: 0.35; }

/* 短 ID 芯片 */
.idchips { display: flex; gap: 8px; margin-top: 8px; flex-wrap: wrap; }
.idchip { border: 1px dashed #d8cfc2; background: #fbfaf8; color: var(--muted); font-size: 12px; padding: 3px 10px; border-radius: 99px; }
.idchip:hover { color: var(--accent); border-color: var(--accent); }

/* 关注按钮 */
.follow { padding: 2px 10px; font-size: 12px; border-radius: 99px; margin-left: 4px; }
.follow.on { background: var(--accent-soft); border-color: #fed7aa; color: var(--accent-deep); }

/* diff */
.diffbox del { background: #fee2e2; color: var(--danger); text-decoration: line-through; border-radius: 3px; padding: 0 1px; }
.diffbox ins { background: var(--ok-soft); color: var(--ok); text-decoration: none; border-radius: 3px; padding: 0 1px; }

/* 提案弹窗输入 */
.ptextarea { width: 100%; min-height: 110px; border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; font-size: 13.5px; line-height: 1.8; font-family: inherit; resize: vertical; margin: 10px 0 8px; outline-color: var(--accent); }
.pnote { width: 100%; border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px; font-size: 13px; outline-color: var(--accent); }

/* 中英对照 */
.trblock h4 { margin: 14px 0 6px; font-size: 13.5px; }
.trblock:first-child h4 { margin-top: 0; }

/* AI 工坊 */
.aibox { border: 1px solid #c7d2fe; background: #f5f7ff; border-radius: 12px; padding: 12px 14px; margin-bottom: 16px; }
.aibox h4 { font-size: 14px; margin-bottom: 8px; }
.aibox h4 .hint { font-weight: 400; font-size: 12px; color: var(--muted); }
.extvars { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }

/* 可见性选择 */
.visrow { display: flex; gap: 10px; }
.visopt { flex: 1; border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; font-size: 13.5px; cursor: pointer; display: block; }
.visopt:has(input:checked) { border-color: var(--accent); background: #fff7ed; }
.visopt input { margin-right: 6px; }
.visopt small { display: block; color: var(--muted); font-size: 12px; margin-top: 2px; font-weight: 400; }

/* 资产库列表 */
.mine-list { display: flex; flex-direction: column; gap: 10px; margin-bottom: 8px; }
.assetrow { display: flex; align-items: center; gap: 12px; background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px 10px 10px; }
.assetrow img { width: 56px; height: 56px; object-fit: cover; border-radius: 9px; }
.ar-main { flex: 1; min-width: 0; }
.ar-title { font-weight: 700; font-size: 14px; }
.ar-title:hover { color: var(--accent); }
.ar-meta { display: flex; gap: 6px; margin-top: 5px; flex-wrap: wrap; }
.ar-actions { display: flex; flex-direction: column; gap: 6px; align-items: stretch; }
.badge.pub { background: #ecfdf5; color: #047857; border: 1px solid #a7f3d0; }
.badge.priv { background: #f4f1ec; color: var(--muted); }

/* 评论晒图 */
.cimgs { margin-top: 6px; }
.cimg { max-width: 180px; border-radius: 10px; border: 1px solid var(--line); display: block; margin-top: 6px; }
.cimg-thumb { position: relative; display: inline-block; }
.cimg-thumb img { width: 72px; height: 72px; object-fit: cover; border-radius: 8px; border: 1px solid var(--line); }
.cimg-thumb button { position: absolute; top: -6px; right: -6px; border: 0; background: var(--text); color: #fff; width: 18px; height: 18px; border-radius: 99px; font-size: 10px; cursor: pointer; }

/* ---------- 详情画廊：轮播 ---------- */
.gmain-wrap img, #gmain { width: 100%; border-radius: var(--radius); border: 1px solid var(--line); display: block; }
#gvideo iframe { width: 100%; aspect-ratio: 16 / 9; border: 0; border-radius: var(--radius); background: #000; display: block; }
#gvideo video { width: 100%; border-radius: var(--radius); border: 1px solid var(--line); display: block; background: #000; }
.thumbv { position: relative; border-radius: 10px; overflow: hidden; cursor: pointer; border: 2px solid transparent; flex-shrink: 0; }
.thumbv img { width: 84px; display: block; }
.thumbv i, .thumbv span { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-style: normal; color: #fff; background: rgba(0, 0, 0, 0.28); font-size: 20px; }
.thumbv.up span { background: #fbfaf8; color: var(--muted); border: 1px dashed var(--line); border-radius: 10px; font-size: 18px; }
.thumbv.on { border-color: var(--accent); }
.upload-row { display: flex; gap: 10px; align-items: center; margin-top: 10px; }

/* B 站嵌入（旧位保留兼容） */
.bili { position: relative; padding-top: 56.25%; border-radius: 10px; overflow: hidden; background: #000; }
.bili iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* 通用弹窗卡片 */
.modal-card { text-align: left; max-width: 640px; max-height: 86vh; overflow: auto; }
.modal-card h3 { font-size: 17px; }

/* ---------- v0.3 模态制 + 资产库 ---------- */
.modtabs { display: flex; gap: 10px; margin: 0; overflow-x: auto; scrollbar-width: none; padding: 8px 0; }
.modtabs-sticky { position: sticky; top: 60px; z-index: 45; background: rgba(250, 249, 247, 0.94); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.modtabs-sticky .modtab { box-shadow: 0 1px 3px rgba(0,0,0,0.04); }
.modtabs::-webkit-scrollbar { display: none; }
.modtab { flex-shrink: 0; display: flex; align-items: center; gap: 7px; padding: 9px 20px; border-radius: 12px; border: 1px solid var(--line); background: #fff; font-size: 14.5px; font-weight: 600; color: var(--muted); }
.modtab em { font-style: normal; font-size: 11px; opacity: 0.55; }
.modtab.on { background: var(--text); color: #fff; border-color: var(--text); }
.modtab.on em { opacity: 0.75; }

.codetext { font-family: ui-monospace, Consolas, "Courier New", monospace; font-size: 12.5px; line-height: 1.75; }
.vtextarea { flex: 1; border: 1px solid var(--line); border-radius: 9px; padding: 8px 10px; font-size: 12.5px; font-family: ui-monospace, Consolas, monospace; line-height: 1.6; resize: vertical; min-height: 56px; outline-color: var(--accent); }

.lib { display: grid; grid-template-columns: 232px minmax(0, 1fr); gap: 22px; padding: 22px 0 40px; align-items: start; }
.lib-side { position: sticky; top: 76px; display: flex; flex-direction: column; gap: 12px; }
.lib-card { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 14px; }
.lib-user { text-align: center; }
.lib-nav { display: flex; flex-direction: column; gap: 2px; }
.lib-nav hr { border: 0; border-top: 1px dashed var(--line); margin: 5px 0; }
.lib-nav button { text-align: left; border: 0; background: none; padding: 8px 11px; border-radius: 9px; font-size: 14px; color: var(--text); display: flex; justify-content: space-between; align-items: center; cursor: pointer; }
.lib-nav button:hover { background: #f4f1ec; }
.lib-nav button.on { background: var(--accent-soft); color: var(--accent-deep); font-weight: 700; }
.lib-nav em { font-style: normal; font-size: 12px; color: var(--muted); }
.lib-nav button.on em { color: var(--accent-deep); }
.lib-main { min-height: 60vh; }
.lib-actions { display: flex; gap: 10px; margin: 4px 0 6px; }
.statcards { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 16px; }
.statcard { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 13px 16px; }
.statcard b { font-size: 20px; display: block; line-height: 1.3; }
.statcard span { font-size: 12px; color: var(--muted); }
@media (max-width: 900px) {
  .lib { grid-template-columns: 1fr; }
  .lib-side { position: static; }
  .statcards { grid-template-columns: repeat(2, 1fr); }
  .modtabs { gap: 8px; }
}

/* ---------- v0.4 积分/套餐/项目/团队 ---------- */
.beta { font-size: 10px; font-weight: 700; letter-spacing: 1.5px; color: #0369a1; background: #e0f2fe; border: 1px solid #bae6fd; padding: 2px 8px; border-radius: 99px; }
.nav-create { background: var(--accent); color: #fff; padding: 7px 16px; border-radius: 10px; font-size: 13.5px; font-weight: 700; white-space: nowrap; }
.nav-create:hover { background: #d94f08; }
.nav-create.on { box-shadow: 0 0 0 2px #fdba74; }
.creditpill { display: inline-flex; align-items: center; gap: 4px; background: #fff7ed; border: 1px solid #fed7aa; color: var(--accent-deep); font-size: 13px; font-weight: 700; padding: 5px 12px; border-radius: 99px; cursor: pointer; white-space: nowrap; }
.creditpill i { font-style: normal; font-size: 10.5px; font-weight: 600; opacity: 0.75; }
.lib-link { display: flex; padding: 8px 11px; border-radius: 9px; font-size: 14px; color: var(--text); }
.lib-link:hover { background: #f4f1ec; }

/* 定价页 */
.pricing { padding-bottom: 40px; }
.p-anchor { position: sticky; top: 60px; z-index: 40; display: flex; gap: 8px; padding: 10px 0; background: rgba(250, 249, 247, 0.94); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.p-anchor a { padding: 6px 18px; border-radius: 99px; border: 1px solid var(--line); background: #fff; font-size: 13.5px; color: var(--muted); }
.p-anchor a:hover { color: var(--accent); border-color: var(--accent); }
.p-zone { scroll-margin-top: 112px; }
.p-zone > .zone-title { font-size: 15px; font-weight: 800; color: var(--muted); margin: 24px 0 2px; letter-spacing: 1px; }
.p-hero { text-align: center; padding: 34px 0 10px; }
.p-hero h1 { font-size: 28px; }
.p-hero h1 b { color: var(--accent); }
.p-hero p { color: var(--muted); margin-top: 8px; font-size: 14px; }
.tiers { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin: 22px 0 8px; }
.tcard { position: relative; background: #fff; border: 1.5px solid var(--line); border-radius: 16px; padding: 20px; text-align: center; }
.tcard.hot { border-color: var(--accent); box-shadow: 0 12px 32px rgba(234, 88, 12, 0.12); }
.tcard.cur { border-color: #94a3b8; }
.ttag { position: absolute; top: -11px; left: 50%; transform: translateX(-50%); background: var(--accent); color: #fff; font-size: 11px; font-style: normal; padding: 2px 12px; border-radius: 99px; }
.tname { font-weight: 800; font-size: 15px; }
.tprice { font-size: 32px; font-weight: 800; margin: 8px 0 4px; }
.tprice span { font-size: 13px; color: var(--muted); font-weight: 400; }
.tier-mini { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 10px; text-align: left; }
.tier-mini .tcard { padding: 14px; }
.tier-mini b { font-size: 14px; }
.tier-mini p { font-size: 12px; color: var(--muted); margin: 6px 0 10px; }
.tcard ul { list-style: none; text-align: left; margin: 12px 0 16px; }
.tcard li { font-size: 13px; padding: 4px 0; color: var(--text); }
.tcard li::before { content: "✓"; color: var(--accent); font-weight: 800; margin-right: 8px; }
.packs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; max-width: 560px; }
.pack { position: relative; background: #fff; border: 1.5px solid var(--line); border-radius: 14px; padding: 18px; text-align: center; }
.pack.best { border-color: var(--accent); }
.pack b { font-size: 18px; }
.pack p { font-size: 12.5px; color: var(--muted); margin: 8px 0 12px; }
.p-block { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 22px 24px; margin-top: 18px; }
.p-block h2 { font-size: 17px; margin-bottom: 6px; }
.p-block h2 .keep { color: var(--accent); }
.cost-table { width: 100%; border-collapse: collapse; margin-top: 10px; font-size: 13.5px; }
.cost-table th, .cost-table td { text-align: left; padding: 8px 10px; border-bottom: 1px dashed var(--line); }
.cost-table th { color: var(--muted); font-weight: 600; font-size: 12.5px; }
.feature { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.feature p { font-size: 13.5px; color: var(--muted); margin: 6px 0 12px; }
.price-mini { display: flex; gap: 10px; margin: 12px 0 4px; }
.price-mini .btn { flex: 1; }

/* 变体矩阵 */
.matrix-box { border: 1px dashed #c4b5fd; background: #faf8ff; border-radius: 12px; padding: 12px 14px; margin-top: 14px; }
.matrix-box h4 { font-size: 13.5px; margin-bottom: 8px; }
.mx-pick { display: flex; flex-direction: column; gap: 6px; }
.mx-var { font-size: 13px; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.mx-var b { color: var(--accent-deep); width: 70px; font-size: 12.5px; }
.mx-var label { display: inline-flex; align-items: center; gap: 3px; background: #fff; border: 1px solid var(--line); border-radius: 99px; padding: 2px 10px; font-size: 12.5px; cursor: pointer; }
.mx-var label:has(input:checked) { border-color: var(--accent); background: #fff7ed; color: var(--accent-deep); }
.mxrow { display: flex; gap: 8px; align-items: center; padding: 6px 0; border-bottom: 1px dashed var(--line); }
.mxno { color: var(--accent); font-weight: 700; font-size: 12px; flex-shrink: 0; width: 32px; }
.mxtxt { flex: 1; font-size: 12.5px; word-break: break-all; }

/* 对比台 */
.cmp-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 12px; }
.cmp-col h4 { font-size: 13.5px; margin-bottom: 6px; }
.cmp-col .preview { min-height: 120px; max-height: 340px; overflow: auto; font-size: 12px; }
@media (max-width: 900px) { .cmp-grid, .feature, .tiers, .tier-mini { grid-template-columns: 1fr; } }

/* 项目页 */
.prj-head { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 24px 0 6px; flex-wrap: wrap; }
.prj-head h2 { font-size: 22px; }
.prj-stats { display: flex; gap: 14px; color: var(--muted); font-size: 13px; margin-top: 6px; flex-wrap: wrap; }
.prj-stats b { color: var(--text); }
.prj-tools { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.prj-select { height: 36px; border: 1px solid var(--line); border-radius: 10px; background: #fff; padding: 0 8px; font-size: 13px; }
.prj-layout { display: grid; grid-template-columns: 230px minmax(0, 1fr); gap: 20px; padding: 14px 0 40px; align-items: start; }
.tree-ep { font-weight: 700; font-size: 13.5px; padding: 7px 8px 3px; }
.tree-ep.muted { color: var(--muted); font-weight: 400; }
.tree-sc { display: block; width: 100%; text-align: left; border: 0; background: none; padding: 5px 8px 5px 18px; font-size: 13px; color: var(--muted); border-radius: 8px; cursor: pointer; }
.tree-sc:hover { background: #f4f1ec; color: var(--text); }
.tree-sc em { font-style: normal; font-size: 11px; opacity: 0.6; }
.shotcard { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; margin-bottom: 10px; }
.shot-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.shot-head b { font-size: 14px; }
.shot-model { margin-left: auto; font-size: 12px; color: var(--muted); }
.shot-desc { font-size: 13.5px; margin: 7px 0; }
.shot-recipe { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.badge.ok { background: #ecfdf5; color: #047857; border: 1px solid #a7f3d0; }
.badge.warn { background: #fffbeb; color: var(--warn); border: 1px solid #fde68a; }
@media (max-width: 900px) { .prj-layout { grid-template-columns: 1fr; } }

/* 团队 */
.team-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; padding: 10px 0 40px; align-items: start; }
@media (max-width: 900px) { .team-grid { grid-template-columns: 1fr; } }
.lockmark { display: inline-block; font-size: 11px; font-weight: 400; padding: 2px 8px; border-radius: 99px; background: #f4f1ec; color: var(--muted); vertical-align: middle; }

/* ---------- v0.5 资产箱 + 画布 ---------- */
.badge.team { background: var(--info-soft); color: var(--info); border: 1px solid #bfdbfe; }
.brand-grid { display: grid; grid-template-columns: 140px 1fr 1fr; gap: 18px; align-items: start; }
.brand-logo { text-align: center; }
#logo-box svg { border-radius: 20px; box-shadow: 0 6px 18px rgba(0,0,0,0.12); }
@media (max-width: 900px) { .brand-grid { grid-template-columns: 1fr; } }
.brand-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; margin-bottom: 12px; }
.bcard { background: #fbfaf8; border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; }
.bcard-head { display: flex; align-items: center; gap: 8px; }
.bcard-head b { font-size: 14px; flex-shrink: 0; }
.bcard-head .del { margin-left: auto; border: 0; background: none; color: var(--muted); cursor: pointer; }
.bcard-dna { font-size: 12.5px; color: var(--muted); margin-top: 6px; line-height: 1.7; }
.brand-add { display: grid; grid-template-columns: 160px 1fr auto; gap: 8px; align-items: center; }
.brand-add textarea { grid-column: 1 / 3; border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; font-size: 12.5px; font-family: inherit; resize: vertical; }
.brand-add input { border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; font-size: 13px; }
@media (max-width: 900px) { .brand-add { grid-template-columns: 1fr; } .brand-add textarea { grid-column: 1; } }

/* ---------- 新建页类型卡片 + 合集 ---------- */
.typecards { display: grid; grid-template-columns: repeat(5, minmax(0,1fr)); gap: 10px; }
.typecard { border: 1.5px solid var(--line); background: #fff; border-radius: 12px; padding: 14px 10px; text-align: center; cursor: pointer; transition: 0.15s; }
.typecard span { font-size: 24px; display: block; }
.typecard b { display: block; font-size: 13.5px; margin: 5px 0 2px; }
.typecard small { font-size: 11px; color: var(--muted); }
.typecard.on { border-color: var(--accent); background: #fff7ed; }
.pickgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 8px; max-height: 320px; overflow: auto; padding: 2px; }
.pickitem { display: flex; gap: 8px; align-items: center; border: 1px solid var(--line); border-radius: 10px; padding: 6px 8px; cursor: pointer; font-size: 12.5px; background: #fff; }
.pickitem img { width: 40px; height: 40px; border-radius: 7px; object-fit: cover; }
.pickitem:has(input:checked) { border-color: var(--accent); background: #fff7ed; }
@media (max-width: 900px) { .typecards { grid-template-columns: repeat(2, 1fr); } }

/* ---------- P2：法律页（原 agreement/privacy 页内 <style>，两页重复收编） ---------- */
.legal { max-width: 780px; margin: 30px auto 60px; background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 34px 38px; }
.legal h1 { font-size: 22px; margin-bottom: 4px; }
.legal .up { color: var(--muted); font-size: 12.5px; margin-bottom: 18px; }
.legal h2 { font-size: 16px; margin: 22px 0 8px; }
.legal p, .legal li { font-size: 13.5px; color: #374151; line-height: 1.9; }
.legal ul { padding-left: 20px; }
.legal .warn { background: #fffbeb; border: 1px solid #fde68a; border-radius: 10px; padding: 10px 14px; font-size: 12.5px; color: #92400e; margin-bottom: 16px; }

/* ---------- P2：小组件（原 JS 模板内联样式收编） ---------- */
/* 积分消耗小标（detail/create 的 ⚡n 角标） */
.cost { font-style: normal; font-size: 10px; color: var(--accent-deep); }
/* 表格空态（settings 订单 / 积分流水） */
.t-empty { color: #9ca3af; }
/* 警示色通知卡（team 品牌箱锁版提示） */
.notice-warn { background: #fffbeb; border-color: #fde68a; }
/* 创作者订阅横幅（creator） */
.sub-banner { background: linear-gradient(135deg, #fffbeb, #fef3c7); border-color: #fde68a; display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.sub-banner > div { flex: 1; min-width: 240px; }
/* 创作者等级章（creator，原 LEVEL_STYLE 内联色） */
.lv.lv3 { background: #fef3c7; color: #92400e; }
.lv.lv2 { background: #e0f2fe; color: #0369a1; }
.lv.lv1 { background: #f3f4f6; color: #6b7280; }
/* 创作激励卡（me 资产库 overview） */
.lib-card.incentive { margin-bottom: 16px; background: #f0fdf4; border-color: #bbf7d0; }
/* 团队积分池上限输入 */
#cap-input { width: 90px; border: 1px solid #fed7aa; border-radius: 8px; padding: 5px 8px; }

/* ---------- P2：详情页连续浏览（相似推荐 / 上一条 · 下一条） ---------- */
.pnav { display: flex; justify-content: space-between; gap: 12px; margin-top: 18px; }
.pn-link { display: inline-flex; align-items: center; gap: 8px; min-width: 0; max-width: 48%; }
.pn-link .pn-title { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); font-size: 12.5px; }
.pn-link.next { margin-left: auto; }
.pn-link.off { opacity: 0.45; cursor: default; pointer-events: none; }

/* ---------- P2：create.html 内联样式收编（表单组件） ---------- */
.create-head { margin-top: 20px; }
.box.flush { margin-top: 0; }
.f-grid { display: flex; gap: 12px; }
.f-grid > div { flex: 1; }
.f-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.ai-actions { margin-top: 6px; flex-wrap: wrap; }
.filehide { display: none; }
#f-mod, #pay-field, #form-collection { display: none; }
#sub-price-row { display: none; margin-top: 8px; }
#sub-price-row .hint { margin-left: 8px; }
#f-subprice { max-width: 220px; }
#ai-result, #addVar { margin-top: 8px; }
#cover-img { width: 64px; height: 64px; border-radius: 8px; object-fit: cover; border: 1px solid var(--line); display: none; }
#f-video { flex: 1; min-width: 220px; border: 1px solid var(--line); border-radius: 8px; padding: 7px 10px; font-size: 12.5px; }
#submitBtn, #c-save { max-width: 280px; }
#submitBtn + .insert-tip { margin-top: 8px; }
#live-preview { min-height: 90px; }
.preview-box h4:not(:first-child) { margin-top: 18px; }
#cover-preview { width: 100%; border-radius: 10px; border: 1px solid var(--line); }

/* ---------- P2：移动端页头（≤900px 汉堡菜单） ---------- */
.nav-burger { display: none; border: 1px solid var(--line); background: #fff; border-radius: 10px; padding: 6px 12px; font-size: 16px; line-height: 1.3; color: var(--text); }
.hmenu { display: none; }
@media (max-width: 900px) {
  #mt-header nav, #mt-header .hright .nav-pricing, #mt-header .hright .nav-dropdown, #mt-header .hright > .badge.member, #h-pay { display: none; }
  .logo { flex: none; white-space: nowrap; }
  .logo span { display: none; }
  .logo-mark { width: 22px; height: 22px; }
  .hrow { gap: 8px; }
  .nav-burger { display: block; }
  #mt-header .hmenu.open { display: block; }
  .hmenu { border-top: 1px solid var(--line); padding: 8px 24px 12px; background: #fff; }
  .hmenu a { display: block; padding: 9px 4px; font-size: 14.5px; color: var(--text); border-radius: 8px; }
  .hmenu a:hover { background: #f4f1ec; color: var(--accent); }
  .hmenu a.on { color: var(--accent); font-weight: 700; }
  .hmenu .nav-group { padding: 8px 4px 2px; }
}
