/* Human Map · 新拟物派 Neumorphism / Soft UI（唯一权威样式源，禁止风格漂移）
   ── 风格铁律（违反即重写） ──
   · 背景 #e0e5ec / 抬升 #e6ebf2 / 凹槽 #d5dbe5，只用浅灰蓝单色系，禁纯黑纯白底
   · 双光源阴影固定左上亮(-X,-Y)#ffffff、右下暗(+X,+Y)#b8bcc2，禁黑色硬投影
   · 按钮 hover 阴影缩小（手指遮光），active 凸→凹 inset，禁任何 translate 浮起
   · 输入框默认深凹陷，focus 内阴影减小（通道开放），禁 focus 增大阴影
   · 强调色 #6d5dfc（CTA 实底配白字），禁渐变背景、禁粗边框、禁直角
   · 圆角 12-24px；交互过渡统一 ≥300ms ease-in-out（Smooth Molding）
   · 元素与背景同色系，靠阴影分层，不靠边框与高对比配色 */

:root {
  /* ──── 新拟物 · 浅灰蓝单色底 ──── */
  --cream-0: #E0E5EC;     /* 主背景 */
  --cream-1: #D5DBE5;     /* 受光暗部基色 */
  --cream-2: #E6EBF2;     /* 抬升高光面 */
  --cream-3: #CCD3DE;     /* 深暗灰蓝（轨道/凹槽） */

  /* 正文墨色：主 #333 / 次级灰统一加深一档，保证对比度 */
  --ink: #333333;
  --ink-80: #3d3d3d;
  --ink-soft: #4d4d4d;
  --ink-faint: #5c5c5c;
  --ink-muted: #7a7a7a;

  /* 发丝分界线 */
  --line: rgba(51, 51, 51, 0.10);
  --line-soft: rgba(51, 51, 51, 0.06);

  /* ──── 新拟物 · 双光源阴影体系 ──── */
  --neu-shadow: #b8bcc2;  /* 右下暗阴影 */
  --neu-bright: #ffffff;  /* 左上亮高光 */

  --neu-raise-xs: 2px 2px 5px var(--neu-shadow), -2px -2px 5px var(--neu-bright);
  --neu-raise-sm: 4px 4px 8px var(--neu-shadow), -4px -4px 8px var(--neu-bright);
  --neu-raise-md: 8px 8px 16px var(--neu-shadow), -8px -8px 16px var(--neu-bright);
  --neu-raise-lg: 12px 12px 24px var(--neu-shadow), -12px -12px 24px var(--neu-bright);
  --neu-raise-xl: 16px 16px 32px var(--neu-shadow), -16px -16px 32px var(--neu-bright);
  --neu-raised-hover: 4px 4px 8px var(--neu-shadow), -4px -4px 8px var(--neu-bright);
  --neu-press: inset 4px 4px 8px var(--neu-shadow), inset -4px -4px 8px var(--neu-bright);
  --neu-press-sm: inset 2px 2px 4px var(--neu-shadow), inset -2px -2px 4px var(--neu-bright);
  --neu-inset: inset 6px 6px 12px var(--neu-shadow), inset -6px -6px 12px var(--neu-bright);
  --neu-inset-focus: inset 2px 2px 4px var(--neu-shadow), inset -2px -2px 4px var(--neu-bright);

  /* 强调色柔光（替代黑投影的漫射提示，保持左上/右下光轴） */
  --glow-rose: 0 8px 20px rgba(109, 93, 252, 0.16);
  --glow-rose-lg: 0 12px 28px rgba(109, 93, 252, 0.20);
  --glow-gold: 0 8px 20px rgba(51, 51, 51, 0.12);
  --glow-gold-lg: 0 12px 28px rgba(51, 51, 51, 0.16);
  --glow-midnight: 0 12px 30px rgba(90, 100, 120, 0.20);

  /* ──── 存量变量向后兼容映射 ──── */
  --bg-0: var(--cream-0);
  --bg-1: var(--cream-0);
  --bg-2: var(--cream-1);
  --paper: var(--cream-0);
  --bg: var(--cream-0);

  --glass-1: var(--cream-0);
  --glass-2: var(--cream-2);
  --glass-3: var(--cream-0);
  --glass-blur: blur(0px);
  --glass-blur-sm: blur(0px);
  --glass-blur-lg: blur(0px);
  --surface-1: var(--cream-0);
  --surface-2: var(--cream-2);
  --surface-3: var(--cream-3);
  --panel: var(--cream-0);
  --panel-solid: var(--cream-2);

  --rim: rgba(184, 188, 194, 0.55);
  --rim-soft: rgba(184, 188, 194, 0.35);
  --rim-hi: #ffffff;
  --rim-bottom: var(--line);

  --depth: var(--neu-raise-md);
  --depth-lg: var(--neu-raise-lg);
  --depth-sm: var(--neu-raise-sm);

  /* 强调 = 新拟物紫 #6d5dfc；CTA 实底配白字 */
  --accent: #6d5dfc;
  --accent-deep: #5646e8;
  --accent-bright: #8f83ff;
  --accent-soft: rgba(109, 93, 252, 0.12);
  --accent-line: rgba(109, 93, 252, 0.30);
  --accent-glow: var(--glow-rose);
  --on-accent: #ffffff;
  --cta: #6d5dfc;
  --cta-deep: #5646e8;
  --cta-soft: rgba(109, 93, 252, 0.14);
  --on-cta: #ffffff;

  /* 金（会员/勋章语义） */
  --gold: #c9a24b;
  --gold-bright: #dcb968;
  --gold-deep: #a8823c;
  --gold-soft: rgba(201, 162, 75, 0.16);
  --gold-line: rgba(201, 162, 75, 0.35);
  --gold-glow: var(--glow-gold);

  /* 玫瑰→并入强调紫系 */
  --rose: #8d80ff;
  --rose-bright: #a89cff;
  --rose-deep: #5646e8;
  --rose-soft: rgba(109, 93, 252, 0.12);
  --rose-line: rgba(109, 93, 252, 0.30);
  --mauve: #4a3fc4;
  --mauve-soft: rgba(74, 63, 196, 0.12);

  /* 语义色：柔化单色系，仅状态用 */
  --green: #2aa38f;
  --green-soft: rgba(42, 163, 143, 0.14);
  --red: #cf5b52;
  --red-soft: rgba(207, 91, 82, 0.12);
  --sky: #64748b;
  --sky-soft: rgba(100, 116, 139, 0.12);
  --cherry: var(--rose-deep);
  --cherry-soft: var(--rose-soft);
  --sun: #a07c2c;
  --sun-soft: rgba(160, 124, 44, 0.14);
  --lavender: var(--mauve);
  --lavender-soft: var(--mauve-soft);
  --blue: var(--sky);
  --purple: var(--accent);

  /* 圆角：新拟物 12-24px，禁直角 */
  --r: 16px;
  --r-sm: 12px;
  --r-lg: 24px;
  --sidebar-w: 240px;

  --sans: -apple-system, "SF Pro Text", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --serif: "Didot", "Bodoni 72", "Playfair Display", Georgia, "Songti SC", "STSong", "Noto Serif CJK SC", "SimSun", serif;
  --mono: "SF Mono", ui-monospace, "JetBrains Mono", Menlo, monospace;
  --typewriter: "Courier New", Courier, "SF Mono", monospace;

  /* Smooth Molding：交互过渡 300ms ease-in-out */
  --ease: ease-in-out;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --dur-fast: 0.3s;
  --dur: 0.3s;
  --dur-slow: 0.5s;
  --dur-melt: 2s;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }

html { background: var(--cream-0); }
body {
  background-color: var(--cream-0);
  color: var(--ink-80);
  font-family: var(--sans);
  font-size: 16px; line-height: 1.75; letter-spacing: 0.01em;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
html { scroll-behavior: smooth; }
button { font-family: inherit; -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
a, input, textarea, select, .card, .tag { -webkit-tap-highlight-color: transparent; }
::selection { background: rgba(109, 93, 252, 0.28); color: var(--ink); }

/* ═══════════ 编辑风排版：衬线标题（weight 400）+ 金色点缀 ═══════════ */
h1, h2, h3, h4 {
  font-family: var(--serif);
  font-weight: 400;
  letter-spacing: -0.015em;
  line-height: 1.3;
  color: var(--ink);
}
.serif { font-family: var(--serif); }
.serif-italic { font-family: var(--serif); font-style: italic; }

.eyebrow {
  display: flex; align-items: center; gap: 12px;
  font-family: var(--sans);
  font-size: 11px; font-weight: 500; letter-spacing: 0.2em;
  text-transform: uppercase; color: var(--gold-deep);
  margin-bottom: 12px;
}
.eyebrow::before { content: ''; width: 34px; height: 1px; background: var(--gold); opacity: 0.7; flex-shrink: 0; }
.eyebrow.center { justify-content: center; }
.eyebrow.center::after { content: ''; width: 34px; height: 1px; background: var(--gold); opacity: 0.7; flex-shrink: 0; }

.tw-cursor::after {
  content: '▍'; margin-left: 3px; color: var(--gold);
  animation: twBlink 1.1s steps(1) infinite;
}
@keyframes twBlink { 50% { opacity: 0; } }
.tw-rule {
  height: 0; margin: 24px 0; border: none;
  border-top: 1px dashed var(--line);
}

/* 叠影大字：午夜蓝幽灵字 */
.stack-title { position: relative; display: inline-block; }
.stack-title .ghost {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -54%);
  font-family: var(--serif); font-style: italic; white-space: nowrap;
  font-size: clamp(56px, 9vw, 108px); color: rgba(51, 51, 51, 0.07);
  pointer-events: none; user-select: none; z-index: 0;
}
.stack-title > :not(.ghost) { position: relative; z-index: 1; }

/* ════════════ 侧边栏：午夜蓝深度层（非对称纵深，金色发丝节奏） ════════════ */
.hm-layout { display: flex; min-height: 100vh; }

.hm-sidebar {
  position: fixed; top: 0; left: 0; bottom: 0;
  width: var(--sidebar-w);
  background: var(--cream-0);
  box-shadow: 6px 0 16px -12px rgba(90, 100, 120, 0.4);
  display: flex; flex-direction: column;
  z-index: 100;
  overflow-y: auto; overflow-x: hidden;
  scrollbar-width: none;
}
.hm-sidebar::-webkit-scrollbar { display: none; }

.hm-sidebar-head { padding: 22px 20px 16px; flex-shrink: 0; }
.hm-brand {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 400; font-size: 19px; letter-spacing: 0.08em;
  text-decoration: none; display: block;
  color: var(--ink);
}
.hm-brand .dot { color: var(--gold); }

.hm-nav-group { padding: 8px 10px; }
.hm-nav-label {
  font-family: var(--sans);
  font-size: 10px; font-weight: 500;
  letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--gold-deep);
  padding: 18px 12px 8px;
  user-select: none;
}
.hm-nav-item {
  display: flex; align-items: center; gap: 12px;
  padding: 9px 12px; border-radius: var(--r-sm);
  color: var(--ink-soft); text-decoration: none;
  font-size: 14px; font-weight: 500;
  transition: box-shadow var(--dur) var(--ease), background-color var(--dur) var(--ease),
              color var(--dur) var(--ease), transform var(--dur) var(--ease);
  cursor: pointer; position: relative;
}
.hm-nav-item:hover {
  color: var(--ink); background: var(--cream-0);
  box-shadow: var(--neu-raise-xs);
}
.hm-nav-item.active {
  color: var(--accent-deep); font-weight: 600;
  background: var(--cream-1);
  box-shadow: var(--neu-press-sm);
}
.hm-nav-item .icon { width: 18px; height: 18px; flex-shrink: 0; color: var(--ink-faint); transition: color var(--dur) var(--ease); }
.hm-nav-item:hover .icon { color: var(--accent); }
.hm-nav-item.active .icon { color: var(--accent-deep); }
.hm-nav-item .badge-dot {
  position: absolute; top: 8px; right: 10px;
  min-width: 16px; height: 16px; border-radius: 8px;
  background: var(--red); color: #fff; font-size: 10px; font-weight: 600;
  display: flex; align-items: center; justify-content: center;
  padding: 0 4px; line-height: 1;
}
.hm-nav-item .pro-tag {
  margin-left: auto; font-size: 10px; padding: 2px 7px;
  background: var(--gold); color: #333333;
  border-radius: 4px; font-family: var(--sans); letter-spacing: 0.1em; text-transform: uppercase; font-weight: 700;
}

.hm-nav-group-toggle {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 12px; border-radius: var(--r-sm);
  color: var(--ink-soft); font-size: 14px; font-weight: 500;
  cursor: pointer; border: none; background: none; width: 100%;
  text-align: left; font-family: inherit;
  transition: box-shadow var(--dur) var(--ease), color var(--dur) var(--ease);
}
.hm-nav-group-toggle:hover {
  color: var(--ink);
  background: var(--cream-0);
  box-shadow: var(--neu-raise-xs);
}
.hm-nav-group-toggle .chevron {
  margin-left: auto; transition: transform var(--dur-slow) var(--ease);
  width: 14px; height: 14px; opacity: 0.6; color: var(--ink-faint);
}
.hm-nav-group-toggle[aria-expanded="true"] .chevron { transform: rotate(90deg); }
.hm-nav-sub { padding-left: 26px; display: none; }
.hm-nav-sub.open { display: block; }
.hm-nav-sub .hm-nav-item { font-size: 13px; padding: 6px 12px; }

/* 侧边栏底部 */
.hm-sidebar-foot {
  margin-top: auto; flex-shrink: 0;
  padding: 12px 10px 10px;
}
.hm-sidebar-foot .hm-nav-item { font-size: 13px; font-weight: 500; }
.hm-sidebar-foot a[href="/pricing"] {
  background: var(--cta);
  color: var(--on-cta); font-weight: 700; justify-content: center;
  box-shadow: var(--neu-raise-sm);
}
.hm-sidebar-foot a[href="/pricing"]:hover {
  background: var(--accent-bright);
  box-shadow: var(--neu-raised-hover);
}
.hm-sidebar-foot a[href="/pricing"]:active { box-shadow: var(--neu-press); }

/* 推荐好友横幅 */
.hm-referral-banner {
  flex-shrink: 0;
  display: flex; align-items: center; gap: 8px;
  padding: 10px 14px;
  background: var(--accent-soft);
  text-decoration: none;
  transition: background var(--dur) var(--ease);
}
.hm-referral-banner:hover { background: rgba(109, 93, 252, 0.18); }
.hm-referral-icon { font-size: 18px; color: var(--gold); }
.hm-referral-text { font-size: 13px; font-weight: 600; color: var(--gold-bright); letter-spacing: 0.04em; }

/* 左下角用户卡（奶油凸起，从午夜蓝中跃出 —— 新拟物对比奇想） */
.hm-user-card {
  flex-shrink: 0;
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px 8px; margin: 4px 6px;
  border-radius: var(--r-sm);
  background: var(--cream-2);
  border: 1px solid rgba(201, 162, 75, 0.4);
  box-shadow: 3px 3px 7px var(--neu-shadow), -3px -3px 7px var(--neu-bright);
  overflow: hidden; max-width: 100%;
}
/* 近况气泡：有状态 = 醒目软胶囊；无状态 = 紧凑虚线占位，不占整行 */
.hm-mood {
  flex-shrink: 0; display: flex; align-items: center; gap: 7px;
  width: calc(100% - 12px); margin: 2px 6px;
  padding: 8px 12px; border: none; border-radius: var(--r-sm);
  background: var(--accent-soft); color: var(--ink-80);
  font-size: 12.5px; line-height: 1.4; text-align: left; cursor: pointer;
  font-family: inherit;
  transition: background var(--dur) var(--ease), color var(--dur) var(--ease);
}
.hm-mood span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hm-mood svg { width: 14px; height: 14px; flex-shrink: 0; color: var(--accent); }
.hm-mood:hover { background: rgba(109, 93, 252, 0.18); color: var(--ink); }
.hm-mood.is-blank {
  width: auto; margin: 0 6px; padding: 3px 10px;
  background: none; color: var(--ink-faint); font-size: 11.5px;
  border: 1px dashed var(--line); border-radius: 999px;
}
.hm-mood.is-blank svg { width: 12px; height: 12px; color: var(--ink-faint); }
.hm-mood.is-blank:hover { color: var(--accent); border-color: var(--accent-line); background: none; }
.hm-user-avatar {
  width: 36px; height: 36px; border-radius: 50%; flex-shrink: 0;
  background: var(--accent);
  color: #ffffff; box-shadow: var(--neu-raise-xs);
  display: flex; align-items: center; justify-content: center;
  font-size: 15px; font-weight: 700; text-decoration: none;
}
.hm-user-info { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.hm-user-name {
  font-size: 13.5px; font-weight: 700; color: var(--ink);
  text-decoration: none; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.hm-user-name:hover { color: var(--rose-deep); }
.hm-ustatus { font-size: 11px; color: var(--ink-faint); }
.hm-ustatus a { color: var(--gold-deep); text-decoration: none; font-weight: 600; }
.hm-ustatus.pro { color: var(--rose-deep); font-weight: 600; }

/* 全局返回按钮 */
.hm-back-btn {
  position: fixed; top: 18px; right: 18px; z-index: 150;
  width: 38px; height: 38px; border-radius: 50%;
  background: var(--cream-2); border: 1px solid rgba(201, 162, 75, 0.35); cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  box-shadow: var(--neu-raise-sm);
  transition: box-shadow var(--dur) var(--ease), color var(--dur) var(--ease);
}
.hm-back-btn svg { width: 18px; height: 18px; color: var(--ink-soft); }
.hm-back-btn:hover { box-shadow: var(--glow-rose); }
.hm-back-btn:hover svg { color: var(--rose-deep); }
.hm-back-btn:active { box-shadow: var(--neu-press); }
@media (max-width: 768px) {
  .hm-back-btn { top: 12px; right: 12px; }
}

/* 右侧内容区 */
.hm-main {
  flex: 1; margin-left: var(--sidebar-w);
  min-height: 100vh;
  display: flex; flex-direction: column;
}
.hm-content {
  flex: 1; width: 100%; max-width: 980px;
  margin: 0 auto; padding: 40px 40px 96px;
}
.hm-content-wide { max-width: 1200px; }
.hm-content-full { max-width: 100%; padding: 40px 28px 96px; }

/* 移动端汉堡菜单 */
.hm-menu-btn {
  display: none; position: fixed; top: 12px; left: 12px; z-index: 200;
  width: 40px; height: 40px; border-radius: var(--r-sm);
  background: var(--cream-2); border: 1px solid rgba(201, 162, 75, 0.35); cursor: pointer;
  align-items: center; justify-content: center;
  font-size: 20px; color: var(--ink);
  box-shadow: var(--neu-raise-sm);
}
.hm-overlay {
  display: none; position: fixed; inset: 0; z-index: 90;
  background: rgba(90, 100, 120, 0.3);
}
.hm-overlay.show { display: block; }

/* ════════════ 按钮（新拟物抬升 + 双光源阴影） ════════════ */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 10px 20px; border-radius: var(--r-sm);
  border: 1px solid transparent; background: var(--cream-2); color: var(--ink);
  font-size: 14px; font-weight: 500; line-height: 1.4;
  font-family: inherit; cursor: pointer; text-decoration: none;
  user-select: none; white-space: nowrap;
  box-shadow: var(--neu-raise-md);
  transition: box-shadow var(--dur) var(--ease), border-color var(--dur) var(--ease),
              background-color var(--dur) var(--ease), color var(--dur) var(--ease),
              opacity var(--dur) var(--ease);
}
.btn:hover { box-shadow: var(--neu-raised-hover); }
.btn:active { box-shadow: var(--neu-press); transition-duration: var(--dur-fast); }
.btn:focus-visible { outline: 2px solid rgba(109, 93, 252, 0.55); outline-offset: 2px; }
.btn:disabled, .btn.disabled { opacity: 0.45; cursor: not-allowed; box-shadow: var(--neu-raise-xs, var(--neu-raise-sm)); }

/* 主按钮：强调色实底 */
.btn-primary {
  background: var(--accent);
  color: #ffffff; border-color: transparent;
  font-weight: 600; font-family: var(--serif); font-style: italic;
  box-shadow: 0 8px 30px -6px rgba(109, 93, 252, 0.45);
}
.btn-primary:hover {
  background: var(--accent-deep);
  color: #ffffff; box-shadow: 0 0 44px rgba(109, 93, 252, 0.5);
}
.btn-primary:active {
  color: #ffffff; box-shadow: inset 3px 3px 6px rgba(18, 18, 46, 0.5), inset -3px -3px 6px rgba(255, 255, 255, 0.18);
}

/* 幽灵按钮：无底仅文字，hover 浮现金色 */
.btn-ghost { background: transparent; border-color: transparent; color: var(--ink-soft); box-shadow: none; }
.btn-ghost:hover { background: var(--gold-soft); color: var(--rose-deep); box-shadow: var(--glow-gold); }
.btn-ghost:active { box-shadow: var(--neu-press-sm); }

/* AI 按钮：金色发丝描边，梦境催化 */
.btn-ai {
  background: var(--cream-2); color: var(--ink);
  border-color: var(--gold-line); font-weight: 600;
  box-shadow: var(--neu-raise-sm);
}
.btn-ai:hover { border-color: var(--rose); background: #e6ebf2; box-shadow: var(--glow-rose); }
.btn-ai:active { box-shadow: var(--neu-press); }

/* 危险按钮：沉郁砖红低调度 */
.btn-danger {
  color: var(--red); border-color: rgba(207, 91, 82, 0.32);
  background: var(--red-soft); font-weight: 500;
}
.btn-danger:hover { background: var(--red-soft); border-color: rgba(207, 91, 82, 0.6); box-shadow: 0 0 28px rgba(207, 91, 82, 0.22); }
.btn-danger:active { box-shadow: var(--neu-press); }

/* 尺寸 */
.btn-sm { padding: 6px 13px; font-size: 13px; border-radius: var(--r-sm); }
.btn-lg { padding: 13px 28px; font-size: 15px; border-radius: var(--r); }
.btn-block { display: flex; width: 100%; justify-content: center; text-align: center; }
.btn-pill { border-radius: 999px; }
.btn .icon, .btn svg { width: 15px; height: 15px; flex-shrink: 0; }

/* ════════════ 卡片（奶油凸起 + 金色发丝 + 双光源阴影） ════════════ */
.card {
  background: var(--cream-2);
  border: 1px solid rgba(201, 162, 75, 0.32); border-radius: var(--r); padding: 20px;
  box-shadow: var(--neu-raise-md);
}
.card-soft {
  background: var(--cream-2);
  border: 1px solid rgba(201, 162, 75, 0.24); border-radius: var(--r); padding: 20px;
  box-shadow: var(--neu-raise-sm);
}
.card-hover {
  transition: box-shadow var(--dur) var(--ease), border-color var(--dur) var(--ease);
}
.card-hover:hover {
  border-color: rgba(109, 93, 252, 0.55);
  box-shadow: var(--neu-raise-lg);
}

/* ════════════ 表单（新拟物凹陷；focus 玫瑰光晕通道开放） ════════════ */
.field { display: block; margin-bottom: 18px; }
.field label { display: block; font-size: 12px; color: var(--ink-faint); margin-bottom: 6px; font-weight: 500; letter-spacing: 0.04em; }
.field input, .field textarea, .field select {
  width: 100%; padding: 11px 14px; border: none; border-radius: var(--r-sm);
  background: var(--cream-1); color: var(--ink); font-size: 14px; font-family: inherit;
  box-shadow: var(--neu-inset);
  transition: box-shadow var(--dur) var(--ease), background-color var(--dur) var(--ease);
}
.field input::placeholder, .field textarea::placeholder { color: var(--ink-faint); }
.field input:focus, .field textarea:focus, .field select:focus {
  outline: none; background: var(--cream-2);
  box-shadow: var(--neu-inset-focus), 0 0 0 2px rgba(109, 93, 252, 0.18);
}
.field select option { background: var(--cream-0); color: var(--ink); }
.field textarea { min-height: 80px; resize: vertical; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.field-row-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 14px; }

/* 全局输入框兜底配方（零特异性，页面类可随时覆盖）：与 .field 同源 */
:where(input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="file"]):not([type="color"]):not([type="submit"]), textarea, select) {
  padding: 11px 14px; border: none; border-radius: var(--r-sm);
  background: var(--cream-1); color: var(--ink); font-size: 14px; font-family: inherit;
  box-shadow: var(--neu-inset);
  transition: box-shadow var(--dur) var(--ease), background-color var(--dur) var(--ease);
}
:where(input::placeholder, textarea::placeholder) { color: var(--ink-faint); }
:where(input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="file"]):not([type="color"]):not([type="submit"]), textarea, select):focus {
  outline: none; background: var(--cream-2);
  box-shadow: var(--neu-inset-focus), 0 0 0 2px rgba(109, 93, 252, 0.18);
}
:where(select option) { background: var(--cream-0); color: var(--ink); }

/* ════════════ 标签（金色发丝 + 午夜蓝字） ════════════ */
.tag {
  display: inline-block; max-width: 100%; padding: 3px 10px;
  background: var(--cream-2); color: var(--ink-soft); border: 1px solid rgba(201, 162, 75, 0.35);
  border-radius: 999px; font-size: 12px; margin: 0 4px 4px 0;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; vertical-align: middle;
}
.tag-green { background: var(--green-soft); color: var(--green); border-color: rgba(42, 163, 143, 0.32); }
.tag-accent { background: var(--gold-soft); color: var(--gold-deep); border-color: var(--gold-line); }
.tag-blue { background: var(--sky-soft); color: var(--sky); border-color: rgba(100, 116, 139, 0.32); }
.tag-purple { background: var(--mauve-soft); color: var(--mauve); border-color: rgba(74, 63, 196, 0.32); }
.tag-red { background: var(--red-soft); color: var(--red); border-color: rgba(207, 91, 82, 0.32); }
.tag-soft { padding: 4px 10px; background: var(--cream-1); color: var(--ink-faint); border-radius: var(--r-sm); font-size: 12px; }
.tag-yellow { background: var(--gold-soft); color: var(--gold-deep); border-color: var(--gold-line); }
.kind-pill { display: inline-block; padding: 2px 9px; font-size: 11px; border-radius: 3px; font-weight: 500; font-family: var(--sans); letter-spacing: 0.08em; text-transform: uppercase; background: var(--gold-soft); color: var(--gold-deep); }

/* ════════════ 完整度环 ════════════ */
.completeness-ring { position: relative; width: 64px; height: 64px; flex-shrink: 0; }
.completeness-ring svg { transform: rotate(-90deg); }
.completeness-ring .ring-bg { fill: none; stroke: var(--line); stroke-width: 4; }
.completeness-ring .ring-fg { fill: none; stroke: var(--ink); stroke-width: 4; stroke-linecap: round; transition: stroke-dashoffset 0.4s; }
.completeness-ring .ring-text { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 600; font-family: var(--mono); color: var(--ink); }

/* ════════════ Empty / Loading ════════════ */
.empty { text-align: center; padding: 60px 20px; color: var(--ink-faint); }
.empty-icon { font-size: 48px; margin-bottom: 12px; opacity: 0.4; color: var(--rose-deep); }
.empty .serif { font-size: 16px; color: var(--ink-soft); }
.spinner { display: inline-block; width: 20px; height: 20px; border: 2px solid var(--line); border-top-color: var(--rose); border-radius: 50%; animation: spin 0.7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ════════════ Modal（奶油凸起 + 金色描边 + 双光源阴影） ════════════ */
.modal-bg { position: fixed; inset: 0; background: rgba(90, 100, 120, 0.3); display: flex; align-items: center; justify-content: center; z-index: 200; padding: 20px; }
.modal {
  background: var(--cream-2);
  border: 1px solid rgba(201, 162, 75, 0.4);
  border-radius: var(--r-lg); max-width: 520px; width: 100%; max-height: 85vh; overflow-y: auto; padding: 30px;
  box-shadow: var(--neu-raise-lg);
}
.modal-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
.modal-head h3 { font-size: 20px; letter-spacing: -0.01em; }
.modal-close { background: none; border: none; font-size: 24px; cursor: pointer; color: var(--ink-soft); line-height: 1; padding: 0; }
.modal-close:hover { color: var(--rose-deep); }
.modal-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 22px; }

/* ════════════ Tabs（金色下划线 + 梦境胶囊） ════════════ */
.hm-tabs-bar { display: flex; gap: 0; margin-bottom: 24px; border-bottom: 1px solid var(--line); }
.hm-tab-btn {
  padding: 10px 22px; font-family: var(--serif); font-size: 16px; font-weight: 400;
  color: var(--ink-faint); cursor: pointer; background: none; border: none;
  border-bottom: 2px solid transparent; margin-bottom: -1px; text-decoration: none;
  transition: color var(--dur) var(--ease), border-color var(--dur) var(--ease);
}
.hm-tab-btn:hover { color: var(--gold-deep); }
.hm-tab-btn.active { color: var(--ink); border-bottom-color: var(--gold); }
@media (max-width: 768px) { .hm-tab-btn { padding: 8px 14px; font-size: 15px; } }
.pill-tabs { display: flex; gap: 8px; flex-wrap: wrap; }
.pill-tab {
  background: var(--cream-2); border: 1px solid rgba(201, 162, 75, 0.3); padding: 6px 15px;
  border-radius: 999px; cursor: pointer; font-size: 13px; color: var(--ink-soft);
  transition: box-shadow var(--dur) var(--ease), border-color var(--dur) var(--ease), color var(--dur) var(--ease);
}
.pill-tab:hover { border-color: var(--rose); color: var(--rose-deep); box-shadow: var(--glow-rose); }
.pill-tab.active { background: var(--gold-soft); border-color: var(--gold-line); color: var(--gold-deep); font-weight: 600; box-shadow: var(--neu-press-sm); }

/* ════════════ 网格 ════════════ */
.hm-grid { display: grid; gap: 18px; }
.hm-grid-2 { grid-template-columns: repeat(2, 1fr); }
.hm-grid-3 { grid-template-columns: repeat(3, 1fr); }
.hm-grid-auto { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }

/* ════════════ 页面标题 ════════════ */
.hm-page-head { margin-bottom: 32px; }
.hm-page-head h1 { font-size: 30px; font-weight: 400; letter-spacing: -0.015em; }
.hm-page-head p { color: var(--ink-soft); font-size: 15px; margin-top: 8px; }

.page-title { font-family: var(--serif); font-size: 30px; font-weight: 400; letter-spacing: 0.02em; margin-bottom: 22px; }
.page-title::after { content: ''; display: block; width: 46px; height: 1px; margin-top: 14px; background: var(--gold); }

/* ════════════ Responsive（移动端阴影收缩） ════════════ */
@media (max-width: 768px) {
  :root {
    --neu-raise-md: 4px 4px 8px var(--neu-shadow), -4px -4px 8px var(--neu-bright);
    --neu-raise-lg: 6px 6px 12px var(--neu-shadow), -6px -6px 12px var(--neu-bright);
    --neu-raise-xl: 8px 8px 16px var(--neu-shadow), -8px -8px 16px var(--neu-bright);
    --neu-inset: inset 4px 4px 8px var(--neu-shadow), inset -4px -4px 8px var(--neu-bright);
  }
  .hm-sidebar { transform: translateX(-100%); transition: transform var(--dur) ease; }
  .hm-sidebar.open { transform: translateX(0); }
  .hm-menu-btn { display: flex; }
  .hm-main { margin-left: 0; padding-bottom: 60px; }
  .hm-content { padding: 56px 16px 28px; }
  .hm-grid-2, .hm-grid-3 { grid-template-columns: 1fr; }
  .field-row, .field-row-3 { grid-template-columns: 1fr; }
  .hm-nav-group { padding: 2px 10px; }

  * { box-sizing: border-box; }
  html, body { overflow-x: hidden; max-width: 100vw; }
  img, video, iframe { max-width: 100%; height: auto; }
  .card, .card-soft { padding: 16px; }
  .page-title { font-size: 24px; }
  .hm-page-head h1 { font-size: 24px; }
  .btn { padding: 10px 16px; font-size: 13.5px; }
  .hm-user-card { padding: 10px 12px; }
  .hm-user-name { font-size: 13px; }
  .hm-referral-banner { padding: 10px 12px; }
  .hm-nav-item { padding: 10px 12px; font-size: 14px; }

  h1 { font-size: 24px; }
  h2 { font-size: 20px; }
  h3 { font-size: 17px; }

  input[type="text"], input[type="email"], input[type="password"], textarea, select {
    font-size: 16px;
  }
}

/* ════════════ 移动端底部Tab栏（午夜蓝延续，active 金状胶囊） ════════════ */
.hm-tab-bar {
  display: none;
  position: fixed;
  bottom: 0; left: 0; right: 0;
  height: 62px;
  background: var(--cream-0);
  box-shadow: 0 -6px 16px -12px rgba(90, 100, 120, 0.4);
  z-index: 100;
  justify-content: space-around;
  align-items: center;
  padding: 4px 8px;
  padding-bottom: env(safe-area-inset-bottom, 0);
}
.hm-tab-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 5px 12px;
  border-radius: var(--r-sm);
  text-decoration: none;
  color: var(--ink-faint);
  font-size: 10px;
  font-weight: 500;
  transition: color var(--dur) var(--ease), background-color var(--dur) var(--ease);
  min-width: 56px;
}
.hm-tab-item .tab-icon { font-size: 20px; line-height: 1; position: relative; }
.hm-tab-item .tab-icon svg { width: 20px; height: 20px; display: block; }
.hm-tab-item .tab-icon .badge-dot {
  position: absolute; top: -6px; right: -12px;
  min-width: 16px; height: 16px; border-radius: 8px;
  background: var(--red); color: #fff; font-size: 10px; font-weight: 600;
  display: flex; align-items: center; justify-content: center; padding: 0 4px; line-height: 1;
}
.hm-tab-item.active {
  color: var(--accent-deep);
  background: var(--cream-1);
  box-shadow: var(--neu-press-sm);
}
.hm-tab-item:active { background: var(--accent-soft); }
@media (max-width: 768px) {
  .hm-tab-bar { display: flex; }
}

@media (min-width: 769px) and (max-width: 1100px) {
  .hm-content { padding: 28px 22px 60px; }
}

/* ════════════ 模态对话框（confirmBox 等） ════════════ */
.modal-overlay { position: fixed; inset: 0; background: rgba(90, 100, 120, 0.3); display: flex; align-items: center; justify-content: center; z-index: 1000; animation: fadeIn 0.3s ease; }
.modal-box {
  background: var(--cream-2);
  border-radius: var(--r-lg); padding: 30px; max-width: 440px; width: calc(100% - 48px);
  box-shadow: var(--neu-raise-lg);
}
.modal-box h3 { font-size: 20px; font-weight: 400; margin: 0 0 8px; }

/* ════════════ 页面过渡动画 ════════════ */
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes slideUp { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }

.onb-card { animation: slideUp 0.5s ease; }

/* ════════════ 骨架屏（奶油上玫褐扫过） ════════════ */
.skeleton {
  background: var(--cream-2);
  animation: skeletonPulse 1.4s ease-in-out infinite;
  border-radius: var(--r-sm);
}
.skeleton-line { height: 14px; margin-bottom: 8px; }
.skeleton-line.short { width: 60%; }
.skeleton-line.medium { width: 80%; }
.skeleton-circle { width: 48px; height: 48px; border-radius: 50%; }
.skeleton-card { height: 120px; margin-bottom: 14px; }
@keyframes skeletonPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.55; }
}

/* ════════════ 空状态 ════════════ */
.empty-state {
  text-align: center; padding: 48px 24px;
  color: var(--ink-soft);
}
.empty-state-icon { font-size: 48px; margin-bottom: 16px; opacity: 0.5; color: var(--rose-deep); }
.empty-state-title { font-family: var(--serif); font-size: 18px; font-weight: 400; color: var(--ink); margin-bottom: 8px; }
.empty-state-desc { font-size: 14px; line-height: 1.7; max-width: 320px; margin: 0 auto 20px; }

/* ════════════ Toast ════════════ */
.toast {
  position: fixed; bottom: 80px; left: 50%;
  transform: translateX(-50%) translateY(16px) scale(0.96);
  background: var(--cream-2);
  border: 1px solid rgba(201, 162, 75, 0.4);
  color: var(--ink); padding: 11px 22px;
  border-radius: 999px; font-size: 14px; z-index: 9999;
  box-shadow: var(--neu-raise-md), var(--glow-gold);
  opacity: 0; pointer-events: none;
  max-width: calc(100vw - 48px); text-align: center;
  transition: opacity var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0) scale(1); }
.toast.error { background: var(--red-soft); border-color: rgba(207, 91, 82, 0.4); color: var(--red); }
.toast.success { background: var(--green-soft); border-color: rgba(42, 163, 143, 0.4); color: var(--green); }

/* ════════════ 交互增强 ════════════ */
input:focus, textarea:focus, select:focus {
  outline: none;
}

@keyframes pageFadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}
.hm-main { animation: pageFadeIn 0.6s ease; }

.modal-box { animation: modalSpringIn 0.6s var(--ease); }
@keyframes modalSpringIn {
  from { opacity: 0; transform: scale(0.97) translateY(10px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

.badge-dot { animation: badgePulse 2s ease-in-out infinite; }
@keyframes badgePulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.7; transform: scale(1.15); }
}

::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(51, 51, 51, 0.2); border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: rgba(109, 93, 252, 0.55); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* ── 兼容旧类：纸面效果 ── */
.glass {
  background: var(--glass-1);
  border-radius: var(--r);
  box-shadow: var(--neu-raise-md);
}
.glass-2 { background: var(--cream-1); }
.glass-3 { background: var(--cream-2); }
.glass-acrylic {
  background: var(--glass-1);
  border-radius: var(--r);
  box-shadow: var(--neu-raise-md);
}

/* ── Unified sizing for linear icons (SVG) ── */
.tag svg { width: 12px; height: 12px; vertical-align: -2px; }
.empty-icon svg { width: 40px; height: 40px; stroke-width: 1.25; }
.empty-state-icon svg { width: 40px; height: 40px; stroke-width: 1.25; }
.np-card-cat svg { width: 12px; height: 12px; vertical-align: -2px; }
.np-help-btn svg { width: 13px; height: 13px; }
.rf-reward-icon svg { width: 26px; height: 26px; stroke-width: 1.25; }
.rf-reward h3 svg { width: 16px; height: 16px; vertical-align: -3px; }
.rf-tree h3 svg { width: 15px; height: 15px; vertical-align: -3px; }
.pay-icon svg { width: 48px; height: 48px; stroke-width: 1.25; }
.match-fallback svg { width: 14px; height: 14px; vertical-align: -2px; }
.match-letter .lbl svg { width: 12px; height: 12px; vertical-align: -2px; }