/* ============================================================
   知更鸟 · AI驱动的全球人文社科学术情报系统 —— 网页版前端
   视觉规范对齐《知更鸟 App MVP 原型》：深紫主色 / 淡紫底 / 白卡片
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+SC:wght@300;400;500;600;700&family=Noto+Serif+SC:wght@400;600;700&display=swap');

:root {
  --primary: #7c3a96;
  --primary-deep: #5b2a70;
  --primary-dark: #4a2160;
  --primary-light: #a86cc0;
  --primary-tint: #f1e7f8;
  --primary-tint-2: #f8f3fb;
  --bg: #f8f5fb;
  --card: #ffffff;
  --border: #ece3f4;
  --border-strong: #d9c8e8;
  --text: #2b2233;
  --text-2: #6b6178;
  --text-3: #9b91a8;
  --success: #2e9e6b;
  --warn: #c77b1f;
  --danger: #c94f4f;
  --radius-lg: 20px;
  --radius-md: 14px;
  --radius-sm: 10px;
  --shadow-card: 0 2px 10px rgba(92, 44, 130, 0.06), 0 1px 3px rgba(92, 44, 130, 0.05);
  --shadow-float: 0 8px 30px rgba(92, 44, 130, 0.16);
  --font: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", "Segoe UI", system-ui, sans-serif;
  --font-serif: "Noto Serif SC", "Songti SC", "SimSun", serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html, body { height: 100%; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* ---------- 顶部导航 ---------- */
.topbar {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.topbar-inner {
  max-width: 1120px; margin: 0 auto; padding: 0 24px;
  height: 64px; display: flex; align-items: center; gap: 28px;
}
.brand { display: flex; align-items: center; gap: 10px; cursor: default; }
.brand-mark {
  width: 34px; height: 34px; border-radius: 10px;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  display: flex; align-items: center; justify-content: center;
  color: #fff; flex-shrink: 0;
}
.brand-name { font-size: 18px; font-weight: 700; color: var(--primary-deep); letter-spacing: 1px; }
.brand-sub { font-size: 11px; color: var(--text-3); margin-top: -2px; }
/* 顶部栏目导航（商业化官网风格：纯文本栏目） */
.main-nav { display: flex; align-items: center; gap: 40px; flex: 1; justify-content: center; }
.nav-item {
  font-size: 14.5px; color: var(--text-2); white-space: nowrap;
  cursor: pointer; transition: color .18s; user-select: none; position: relative;
  padding: 6px 2px;
}
.nav-item::after {
  content: ""; position: absolute; left: 50%; bottom: -2px;
  width: 0; height: 2px; border-radius: 2px;
  background: var(--primary); transition: all .22s ease; transform: translateX(-50%);
}
.nav-item:hover { color: var(--primary); }
.nav-item:hover::after { width: 60%; }
.nav-item.active { color: var(--primary); font-weight: 600; }
.nav-item.active::after { width: 100%; }
.nav-toggle {
  display: none; margin-left: auto; margin-right: 4px;
  width: 38px; height: 38px; border: 1px solid var(--border);
  border-radius: 10px; background: #fff; color: var(--primary-deep);
  align-items: center; justify-content: center; cursor: pointer;
}
.topbar-user {
  display: flex; align-items: center; gap: 10px;
  font-size: 12.5px; color: var(--text-2);
  background: var(--primary-tint); padding: 6px 14px; border-radius: 999px;
}
.topbar-user .avatar {
  width: 22px; height: 22px; border-radius: 50%;
  background: var(--primary); color: #fff;
  display: flex; align-items: center; justify-content: center; font-size: 11px;
}

/* ---------- 主容器 ---------- */
.main { max-width: 1120px; margin: 0 auto; padding: 36px 24px 80px; }
.screen { display: none; animation: screenIn .35s ease; }
.screen.visible { display: block; }
@keyframes screenIn { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

/* ---------- 通用组件 ---------- */
.card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius-lg); box-shadow: var(--shadow-card);
}
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: none; cursor: pointer; font-family: var(--font);
  font-size: 15px; font-weight: 600; border-radius: 999px;
  padding: 13px 30px; transition: all .2s;
}
.btn-primary { background: var(--primary); color: #fff; box-shadow: 0 4px 14px rgba(124,58,150,.28); }
.btn-primary:hover { background: var(--primary-deep); transform: translateY(-1px); }
.btn-primary:disabled { background: #cdb8da; box-shadow: none; cursor: not-allowed; transform: none; }
.btn-ghost {
  background: #fff; color: var(--primary); border: 1.5px solid var(--primary);
}
.btn-ghost:hover { background: var(--primary-tint); }
.btn-block { width: 100%; }
.btn-sm { padding: 8px 18px; font-size: 13px; }

.chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 7px 16px; border-radius: 999px; font-size: 13px;
  background: var(--primary-tint); color: var(--primary-deep);
  border: 1.5px solid transparent; cursor: pointer; transition: all .18s;
  user-select: none;
}
.chip:hover { border-color: var(--border-strong); }
.chip.selected { background: var(--primary); color: #fff; border-color: var(--primary); font-weight: 600; }
.chip .x { font-size: 12px; opacity: .7; margin-left: 2px; }
.chip .x:hover { opacity: 1; }

.badge {
  display: inline-flex; align-items: center;
  font-size: 11px; font-weight: 600; padding: 2px 9px; border-radius: 6px;
  letter-spacing: .5px;
}
.badge-grade-a { background: #ece0f5; color: var(--primary-deep); }
.badge-grade-b { background: #eef1f8; color: #4a5a8a; }
.badge-grade-aplus { background: var(--primary); color: #fff; }
.badge-type { background: var(--primary-tint); color: var(--primary-deep); }
.badge-type-dongtai { background: #e7f0fb; color: #2a5f9e; }
.badge-type-huiyi { background: #fbf1e3; color: var(--warn); }
.badge-type-jijin { background: #eaf7ef; color: var(--success); }
.badge-type-zhaopin { background: #fbeae7; color: #b05448; }

.tag {
  display: inline-flex; padding: 3px 10px; border-radius: 6px;
  font-size: 11.5px; background: var(--primary-tint-2);
  color: var(--text-2); border: 1px solid var(--border);
}

.section-label { font-size: 14.5px; font-weight: 700; color: var(--text); }
.section-hint { font-size: 12px; color: var(--text-3); }

.field-label { font-size: 13.5px; font-weight: 600; color: var(--text); margin-bottom: 9px; display: flex; justify-content: space-between; align-items: baseline; }
.input {
  width: 100%; border: 1.5px solid var(--border-strong); border-radius: var(--radius-md);
  padding: 13px 16px; font-size: 14.5px; font-family: var(--font);
  color: var(--text); background: #fff; outline: none; transition: border .2s, box-shadow .2s;
}
.input::placeholder { color: var(--text-3); }
.input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(124,58,150,.12); }
.input.error { border-color: var(--danger); }
.err-msg { font-size: 12px; color: var(--danger); margin-top: 6px; display: none; }
.err-msg.show { display: block; }

/* ---------- 登录页 ---------- */
.auth-wrap { max-width: 470px; margin: 0 auto; }
.auth-hero { text-align: center; padding: 30px 0 26px; }
.auth-hero .logo-big {
  width: 84px; height: 84px; margin: 0 auto 20px; border-radius: 24px;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  display: flex; align-items: center; justify-content: center;
  box-shadow: var(--shadow-float);
}
.auth-hero h1 { font-size: 27px; color: var(--primary-deep); font-weight: 800; letter-spacing: 1px; }
.auth-hero p { color: var(--text-2); font-size: 13.5px; margin-top: 8px; }
.auth-card { padding: 28px 30px 26px; }
.auth-tabs { display: flex; background: var(--primary-tint-2); border-radius: 999px; padding: 4px; margin-bottom: 24px; }
.auth-tab {
  flex: 1; text-align: center; padding: 9px 0; border-radius: 999px;
  font-size: 14px; font-weight: 600; color: var(--text-2); cursor: pointer; transition: all .2s;
}
.auth-tab.active { background: var(--primary); color: #fff; box-shadow: 0 2px 8px rgba(124,58,150,.3); }
.code-row { display: flex; gap: 10px; }
.code-row .input { flex: 1; }
.btn-code {
  white-space: nowrap; border: 1.5px solid var(--primary); color: var(--primary);
  background: #fff; border-radius: var(--radius-md); padding: 0 18px;
  font-size: 13px; font-weight: 600; cursor: pointer; font-family: var(--font); transition: all .2s;
}
.btn-code:hover:not(:disabled) { background: var(--primary-tint); }
.btn-code:disabled { border-color: var(--border-strong); color: var(--text-3); cursor: not-allowed; }
.agree-row { display: flex; align-items: flex-start; gap: 9px; font-size: 12.5px; color: var(--text-2); margin: 18px 0 20px; cursor: pointer; }
.agree-row a { color: var(--primary); text-decoration: none; font-weight: 600; }
.checkbox {
  width: 17px; height: 17px; border-radius: 5px; border: 1.5px solid var(--border-strong);
  flex-shrink: 0; margin-top: 1px; display: flex; align-items: center; justify-content: center;
  transition: all .15s; background: #fff;
}
.checkbox.checked { background: var(--primary); border-color: var(--primary); }
.checkbox svg { display: none; }
.checkbox.checked svg { display: block; }
.auth-foot { text-align: center; font-size: 12px; color: var(--text-3); margin-top: 16px; }
.auth-tip {
  margin-top: 14px; padding: 10px 14px; border-radius: var(--radius-sm);
  background: #fdf7e8; border: 1px solid #f3e3bb; font-size: 12px; color: #8a6a1f;
  display: none;
}
.auth-tip.show { display: flex; gap: 8px; align-items: flex-start; }
.auth-note { text-align: center; color: var(--text-3); font-size: 11.5px; margin-top: 22px; }

/* ---------- 订阅页 ---------- */
.page-head { margin-bottom: 26px; }
.page-head h1 { font-size: 25px; color: var(--primary-deep); font-weight: 800; }
.page-head .sub { color: var(--text-2); font-size: 13.5px; margin-top: 6px; }
.sub-tabs { display: inline-flex; background: var(--primary-tint-2); border-radius: 999px; padding: 4px; margin-top: 16px; }
.sub-tab {
  padding: 9px 26px; border-radius: 999px; font-size: 13.5px; font-weight: 600;
  color: var(--text-2); cursor: pointer; transition: all .2s; display: flex; gap: 7px; align-items: center;
}
.sub-tab.active { background: var(--primary); color: #fff; box-shadow: 0 2px 8px rgba(124,58,150,.3); }
.sub-tab .cnt { font-size: 11px; opacity: .75; font-weight: 500; }
.sub-layout { display: grid; grid-template-columns: 232px 1fr; gap: 20px; align-items: start; margin-top: 22px; }
.subject-panel { padding: 14px; position: sticky; top: 84px; max-height: calc(100vh - 200px); overflow-y: auto; }
.subject-panel h3 { font-size: 13px; color: var(--text-3); font-weight: 600; padding: 4px 10px 10px; letter-spacing: 1px; }
.subject-item {
  display: flex; justify-content: space-between; align-items: center;
  padding: 9px 12px; border-radius: var(--radius-sm); font-size: 13.5px;
  color: var(--text-2); cursor: pointer; transition: all .15s; margin-bottom: 2px;
}
.subject-item:hover { background: var(--primary-tint-2); color: var(--primary-deep); }
.subject-item.active { background: var(--primary-tint); color: var(--primary-deep); font-weight: 700; }
.subject-item .n { font-size: 11px; color: var(--text-3); }
.subject-item.active .n { color: var(--primary); }
.source-panel { min-height: 400px; }
.source-toolbar { display: flex; gap: 12px; align-items: center; padding: 14px 18px; border-bottom: 1px solid var(--border); position: sticky; top: 84px; background: #fff; border-radius: var(--radius-lg) var(--radius-lg) 0 0; z-index: 5; }
.source-toolbar .input { padding: 9px 14px; font-size: 13.5px; border-radius: 999px; }
.source-list { padding: 8px 18px 18px; }
.source-row {
  display: flex; align-items: center; gap: 14px;
  padding: 13px 6px; border-bottom: 1px solid var(--border);
}
.source-row:last-child { border-bottom: none; }
.source-ico {
  width: 40px; height: 40px; border-radius: 12px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center; font-size: 15px; font-weight: 700;
}
.source-ico.wx { background: #eaf7ef; color: var(--success); }
.source-ico.rss { background: #fbf1e3; color: var(--warn); }
.source-info { flex: 1; min-width: 0; }
.source-name { font-size: 14px; font-weight: 600; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.source-meta { font-size: 11.5px; color: var(--text-3); margin-top: 3px; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.btn-follow {
  border: 1.5px solid var(--primary); color: var(--primary); background: #fff;
  border-radius: 999px; padding: 6px 18px; font-size: 12.5px; font-weight: 600;
  cursor: pointer; font-family: var(--font); transition: all .18s; flex-shrink: 0;
}
.btn-follow:hover { background: var(--primary-tint); }
.btn-follow.on { background: var(--primary-tint); border-color: var(--border-strong); color: var(--text-3); }
.load-more { display: block; margin: 16px auto 0; }
.sub-bottombar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
  background: rgba(255,255,255,.95); backdrop-filter: blur(8px);
  border-top: 1px solid var(--border); padding: 12px 0;
}
.sub-bottombar-inner { max-width: 1120px; margin: 0 auto; padding: 0 24px; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.sub-summary { font-size: 13px; color: var(--text-2); }
.sub-summary b { color: var(--primary); font-size: 16px; }
.empty-box { text-align: center; padding: 60px 20px; color: var(--text-3); font-size: 13.5px; }
.empty-box .ico { font-size: 34px; margin-bottom: 10px; opacity: .5; }

/* ---------- 画像输入页 ---------- */
.profile-grid { display: grid; grid-template-columns: 1.25fr .95fr; gap: 20px; align-items: start; }
.profile-card { padding: 26px 28px; margin-bottom: 18px; }
.stage-chips, .focus-chips { display: flex; flex-wrap: wrap; gap: 9px; }
.kw-box { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; min-height: 20px; }
.kw-suggest { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.kw-suggest .chip { background: #fff; border: 1.5px dashed var(--border-strong); color: var(--text-2); }
.kw-suggest .chip:hover { border-color: var(--primary); color: var(--primary); }
textarea.input { resize: vertical; min-height: 92px; line-height: 1.7; }
.switch-card { display: flex; align-items: flex-start; gap: 12px; padding: 16px 18px; background: var(--primary-tint-2); border-radius: var(--radius-md); margin-top: 18px; border: 1px solid var(--border); }
.switch { position: relative; width: 42px; height: 24px; flex-shrink: 0; margin-top: 2px; }
.switch input { opacity: 0; width: 0; height: 0; }
.slider {
  position: absolute; inset: 0; border-radius: 999px; background: #d8cbe4;
  transition: .25s; cursor: pointer;
}
.slider::before {
  content: ""; position: absolute; width: 18px; height: 18px; border-radius: 50%;
  background: #fff; top: 3px; left: 3px; transition: .25s; box-shadow: 0 1px 4px rgba(0,0,0,.2);
}
.switch input:checked + .slider { background: var(--primary); }
.switch input:checked + .slider::before { transform: translateX(18px); }
.profile-side { position: sticky; top: 84px; }
.side-tip { padding: 20px 22px; }
.side-tip h4 { font-size: 14px; color: var(--primary-deep); margin-bottom: 10px; display: flex; align-items: center; gap: 7px; }
.side-tip li { font-size: 12.5px; color: var(--text-2); margin: 8px 0 8px 16px; }

/* ---------- AI 画像页 ---------- */
.ai-stage { max-width: 620px; margin: 0 auto; }
.ai-run { text-align: center; padding: 46px 30px; }
.ai-orb {
  width: 92px; height: 92px; margin: 0 auto 26px; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, var(--primary-light), var(--primary) 70%);
  box-shadow: 0 0 0 14px rgba(124,58,150,.1), 0 0 0 28px rgba(124,58,150,.05), var(--shadow-float);
  display: flex; align-items: center; justify-content: center;
  animation: pulse 1.6s ease-in-out infinite;
}
@keyframes pulse { 0%,100% { transform: scale(1); } 50% { transform: scale(1.06); } }
.ai-run h2 { font-size: 20px; color: var(--primary-deep); font-weight: 700; }
.ai-run .sub { font-size: 13px; color: var(--text-2); margin-top: 6px; }
.ai-steps { text-align: left; margin: 28px auto 0; max-width: 380px; }
.ai-step {
  display: flex; align-items: center; gap: 12px; padding: 11px 4px;
  color: var(--text-3); font-size: 14px; opacity: .45; transition: all .3s;
}
.ai-step .ring {
  width: 20px; height: 20px; border-radius: 50%; border: 2px solid var(--border-strong);
  flex-shrink: 0; display: flex; align-items: center; justify-content: center; font-size: 11px;
}
.ai-step.running { opacity: 1; color: var(--primary); font-weight: 600; }
.ai-step.running .ring { border-color: var(--primary); border-top-color: transparent; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.ai-step.done { opacity: 1; color: var(--text-2); }
.ai-step.done .ring { background: var(--primary); border-color: var(--primary); color: #fff; animation: none; }

.portrait-card { padding: 30px 32px; margin-top: 20px; }
.portrait-head { display: flex; align-items: center; gap: 16px; padding-bottom: 20px; border-bottom: 1px dashed var(--border-strong); }
.portrait-avatar {
  width: 58px; height: 58px; border-radius: 18px; flex-shrink: 0;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  display: flex; align-items: center; justify-content: center; color: #fff; font-size: 24px;
}
.portrait-head h2 { font-size: 19px; color: var(--primary-deep); }
.portrait-head .sub { font-size: 12.5px; color: var(--text-3); margin-top: 3px; }
.portrait-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 22px; margin-top: 20px; }
.p-item { background: var(--primary-tint-2); border: 1px solid var(--border); border-radius: var(--radius-md); padding: 13px 16px; }
.p-item.full { grid-column: 1 / -1; }
.p-item .k { font-size: 11.5px; color: var(--text-3); font-weight: 600; letter-spacing: 1px; margin-bottom: 6px; }
.p-item .v { font-size: 14px; color: var(--text); font-weight: 600; }
.p-item .tags { display: flex; flex-wrap: wrap; gap: 7px; }
.p-reason { margin-top: 18px; padding: 14px 18px; background: #f6f0fb; border-left: 3px solid var(--primary); border-radius: 8px; font-size: 13px; color: var(--text-2); line-height: 1.8; }
.p-actions { display: flex; gap: 12px; margin-top: 24px; }

/* ---------- 推送页 ---------- */
.digest-card {
  background: linear-gradient(120deg, var(--primary-dark) 0%, var(--primary) 55%, var(--primary-light) 100%);
  color: #fff; border: none; padding: 24px 30px; margin-bottom: 22px;
  display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap;
}
.digest-card h3 { font-size: 18px; font-weight: 700; letter-spacing: .5px; }
.digest-card .sub { font-size: 12.5px; opacity: .82; margin-top: 5px; }
.digest-mail { background: rgba(255,255,255,.14); border: 1px solid rgba(255,255,255,.3); border-radius: var(--radius-md); padding: 13px 18px; font-size: 12.5px; max-width: 380px; }
.digest-mail b { font-size: 14px; }
.feed-toolbar { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin-bottom: 18px; }
.feed-filters { display: flex; gap: 8px; flex-wrap: wrap; flex: 1; }
.feed-toolbar .input { width: 240px; padding: 9px 16px; font-size: 13.5px; border-radius: 999px; }
.feed-list { display: flex; flex-direction: column; gap: 14px; }
.intel-card { padding: 20px 24px; transition: box-shadow .2s, transform .2s; cursor: default; }
.intel-card:hover { box-shadow: var(--shadow-float); transform: translateY(-2px); }
.intel-top { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.match-pill {
  margin-left: auto; display: flex; align-items: center; gap: 6px;
  font-size: 12px; font-weight: 700; color: var(--primary);
  background: var(--primary-tint); padding: 4px 12px; border-radius: 999px;
}
.match-bar { width: 54px; height: 5px; background: #e9def2; border-radius: 4px; overflow: hidden; }
.match-bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--primary-light), var(--primary)); border-radius: 4px; }
.intel-title { font-size: 16px; font-weight: 700; color: var(--text); margin: 10px 0 6px; line-height: 1.5; }
.intel-title:hover { color: var(--primary-deep); cursor: pointer; }
.intel-src { font-size: 12px; color: var(--text-3); display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.intel-src .dot { width: 3px; height: 3px; border-radius: 50%; background: var(--text-3); }
.intel-abs { font-size: 13px; color: var(--text-2); margin-top: 9px; line-height: 1.75; }
.intel-tags { display: flex; gap: 7px; flex-wrap: wrap; margin-top: 11px; }
.intel-basis {
  margin-top: 12px; font-size: 11.5px; color: var(--primary-deep);
  background: var(--primary-tint-2); border-radius: 8px; padding: 7px 12px;
  display: inline-flex; align-items: center; gap: 6px;
}
.intel-actions { display: flex; gap: 8px; margin-top: 14px; }
.mini-btn {
  border: 1px solid var(--border-strong); background: #fff; color: var(--text-2);
  border-radius: 999px; padding: 5px 15px; font-size: 12px; cursor: pointer;
  font-family: var(--font); transition: all .18s; display: inline-flex; align-items: center; gap: 5px;
}
.mini-btn:hover { border-color: var(--primary); color: var(--primary); }
.mini-btn.starred { background: var(--primary-tint); border-color: var(--primary); color: var(--primary); font-weight: 600; }

/* ---------- 弹层 / Toast ---------- */
.modal-mask {
  position: fixed; inset: 0; background: rgba(43,34,51,.45); z-index: 100;
  display: none; align-items: center; justify-content: center; padding: 24px;
  backdrop-filter: blur(3px);
}
.modal-mask.show { display: flex; animation: screenIn .25s ease; }
.modal { max-width: 640px; width: 100%; max-height: 82vh; overflow-y: auto; padding: 28px 30px; }
.modal h2 { font-size: 19px; color: var(--primary-deep); margin: 10px 0 4px; }
.modal .m-meta { font-size: 12px; color: var(--text-3); margin-bottom: 14px; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.modal .m-body { font-size: 13.5px; color: var(--text-2); line-height: 1.85; white-space: pre-line; }
.modal-close { float: right; border: none; background: var(--primary-tint); color: var(--text-2); width: 30px; height: 30px; border-radius: 50%; cursor: pointer; font-size: 15px; }
.toast-wrap { position: fixed; top: 76px; left: 50%; transform: translateX(-50%); z-index: 200; display: flex; flex-direction: column; gap: 8px; align-items: center; }
.toast {
  background: rgba(43,34,51,.92); color: #fff; font-size: 13px;
  padding: 10px 22px; border-radius: 999px; animation: screenIn .25s ease;
  box-shadow: 0 6px 20px rgba(0,0,0,.18);
}
.toast.ok { background: rgba(46,158,107,.95); }
.toast.warn { background: rgba(199,123,31,.95); }

/* ---------- 响应式 ---------- */
@media (max-width: 900px) {
  .main-nav {
    position: absolute; top: 64px; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: #fff; border-bottom: 1px solid var(--border);
    box-shadow: 0 12px 24px rgba(92,44,130,.10);
    display: none; padding: 8px 0;
  }
  .main-nav.open { display: flex; }
  .nav-item { padding: 13px 28px; font-size: 15px; }
  .nav-item::after { display: none; }
  .nav-item.active { background: var(--primary-tint-2); }
  .nav-toggle { display: flex; }
  .sub-layout, .profile-grid, .portrait-grid { grid-template-columns: 1fr; }
  .subject-panel { position: static; max-height: none; }
  .profile-side { position: static; }
}

/* ============================================================
   演示控制台 & 状态界面（审查补全）
   ============================================================ */
.demo-fab {
  position: fixed; right: 26px; bottom: 26px; z-index: 300;
  width: 52px; height: 52px; border-radius: 50%; border: none; cursor: pointer;
  background: var(--primary); color: #fff; display: flex; align-items: center; justify-content: center;
  box-shadow: var(--shadow-float); transition: transform .2s;
}
.demo-fab:hover { transform: scale(1.08); background: var(--primary-deep); }
.demo-panel {
  position: fixed; right: 26px; bottom: 90px; z-index: 300; width: 250px;
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-float); overflow: hidden;
  display: none; animation: screenIn .2s ease;
}
.demo-panel.open { display: block; }
.demo-head {
  display: flex; justify-content: space-between; align-items: center;
  padding: 13px 16px; font-size: 13.5px; font-weight: 700; color: var(--primary-deep);
  background: var(--primary-tint-2); border-bottom: 1px solid var(--border);
}
.demo-close { cursor: pointer; color: var(--text-3); font-size: 13px; padding: 0 4px; }
.demo-close:hover { color: var(--text); }
.demo-body { padding: 12px 14px 16px; }
.demo-group-title { font-size: 11px; color: var(--text-3); font-weight: 700; letter-spacing: 1px; margin-bottom: 7px; }
.demo-btn {
  display: block; width: 100%; text-align: left; margin-bottom: 6px;
  padding: 8px 12px; border-radius: var(--radius-sm); border: 1px solid var(--border);
  background: #fff; color: var(--text); font-size: 12.5px; font-family: var(--font); cursor: pointer;
  transition: all .15s;
}
.demo-btn:hover { border-color: var(--primary); color: var(--primary); background: var(--primary-tint-2); }
.demo-btn.demo-danger { color: var(--danger); border-color: #f1d5d5; }
.demo-btn.demo-danger:hover { background: #fdf1f1; border-color: var(--danger); }

/* 已截止 / 截止日期 / 原文失效徽标 */
.badge-closed { background: #eeeaf1; color: #8a8292; }
.badge-deadline { background: #fdf3e0; color: #a06a12; }
.badge-dead { background: #fbeaea; color: #b05448; }
.intel-card.dimmed { opacity: .68; }
.intel-card.dimmed .intel-title { color: var(--text-2); }

/* 骨架屏 */
.skeleton-card { padding: 20px 24px; }
.sk-line {
  height: 14px; border-radius: 7px; margin-bottom: 12px;
  background: linear-gradient(90deg, #efe9f4 25%, #f7f3fa 50%, #efe9f4 75%);
  background-size: 200% 100%; animation: shimmer 1.3s infinite;
}
.sk-line.w40 { width: 40%; } .sk-line.w65 { width: 65%; }
.sk-line.w90 { width: 90%; height: 18px; } .sk-line.w100 { width: 100%; }
@keyframes shimmer { to { background-position: -200% 0; } }

/* 加载失败 */
.error-box .ico { font-size: 40px; }

/* 详情降级警告条 */
.detail-warn {
  margin: 12px 0 4px; padding: 11px 14px; border-radius: var(--radius-sm);
  font-size: 12.5px; line-height: 1.6;
}
.detail-warn.warn-closed { background: #f6f2f8; border: 1px solid #e3d9ea; color: #6d6280; }
.detail-warn.warn-dead { background: #fdf1f1; border: 1px solid #f1d5d5; color: #a05448; }

/* ============================================================
   会员体系（会员中心 / 档位对比 / 充值支付）
   ============================================================ */
.tier-badge {
  font-size: 11px; font-weight: 700; padding: 2px 9px; border-radius: 999px; flex-shrink: 0;
}
.tier-badge.tier-free { background: #eeeaf1; color: #8a8292; }
.tier-badge.tier-paid { background: linear-gradient(135deg, var(--primary), var(--primary-light)); color: #fff; }
.topbar-user { cursor: pointer; }
.topbar-user:hover { box-shadow: 0 2px 8px rgba(92,44,130,.12); }

/* 会员中心 */
.member-status {
  display: flex; align-items: center; justify-content: space-between; gap: 20px;
  padding: 26px 30px; margin-bottom: 8px; flex-wrap: wrap;
}
.ms-left { flex: 1; min-width: 260px; }
.ms-tier { display: inline-block; font-size: 14px; font-weight: 700; padding: 4px 14px; border-radius: 999px; margin-bottom: 10px; }
.ms-tier.ms-free { background: #eeeaf1; color: #6d6280; }
.ms-tier.ms-paid { background: linear-gradient(135deg, var(--primary), var(--primary-light)); color: #fff; }
.ms-desc { font-size: 13.5px; color: var(--text-2); }
.ms-meta { font-size: 12.5px; color: var(--text-3); margin-top: 12px; }
.ms-meta b { color: var(--primary-deep); }
.ms-expired { margin-top: 12px; padding: 9px 14px; background: #fdf1f1; border: 1px solid #f1d5d5; border-radius: var(--radius-sm); color: #a05448; font-size: 12.5px; }
.ms-right { flex-shrink: 0; }

.member-section-title { font-size: 15px; font-weight: 700; color: var(--primary-deep); margin: 26px 0 14px; }

/* 档位对比 */
.tier-compare { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.tier-card {
  position: relative; background: #fff; border: 1.5px solid var(--border);
  border-radius: var(--radius-lg); padding: 22px 18px; transition: all .2s;
}
.tier-card:hover { border-color: var(--border-strong); box-shadow: var(--shadow-card); }
.tier-card.current { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(124,58,150,.1); }
.tier-card.recommend { border-color: var(--primary-light); }
.tier-ribbon {
  position: absolute; top: -11px; left: 50%; transform: translateX(-50%);
  background: linear-gradient(135deg, var(--primary), var(--primary-light)); color: #fff;
  font-size: 11px; font-weight: 700; padding: 3px 12px; border-radius: 999px;
}
.tier-name { font-size: 15px; font-weight: 700; color: var(--text); }
.tier-price { margin: 12px 0 4px; }
.tier-price b { font-size: 30px; color: var(--primary-deep); font-weight: 800; }
.tier-price span { font-size: 12px; color: var(--text-3); margin-left: 4px; }
.tier-desc { font-size: 12px; color: var(--text-2); min-height: 34px; }
.tier-rights { list-style: none; margin: 14px 0 18px; }
.tier-rights li {
  font-size: 12.5px; color: var(--text-2); padding: 5px 0 5px 20px; position: relative;
}
.tier-rights li::before { content: "✓"; position: absolute; left: 0; color: var(--primary); font-weight: 700; }

/* 充值弹层 */
.pay-modal { max-width: 560px; }
.pay-tiers { display: flex; flex-direction: column; gap: 12px; margin-top: 16px; }
.pay-tier {
  display: flex; align-items: center; gap: 16px; padding: 16px 18px;
  border: 1.5px solid var(--border); border-radius: var(--radius-md); cursor: pointer; transition: all .18s;
}
.pay-tier:hover { border-color: var(--border-strong); }
.pay-tier.sel { border-color: var(--primary); background: var(--primary-tint-2); box-shadow: 0 0 0 3px rgba(124,58,150,.08); }
.pt-head { display: flex; align-items: center; gap: 8px; flex: 1; }
.pt-name { font-size: 14.5px; font-weight: 700; color: var(--text); }
.pt-price b { font-size: 22px; color: var(--primary-deep); font-weight: 800; }
.pt-price span { font-size: 12px; color: var(--text-3); }
.pt-desc { font-size: 12px; color: var(--text-3); }
.pt-check {
  width: 22px; height: 22px; border-radius: 50%; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  background: var(--primary); color: #fff; font-size: 13px; font-weight: 700;
}
.pay-actions { display: flex; gap: 12px; justify-content: flex-end; margin-top: 20px; }

/* 订单确认 */
.order-box { background: var(--primary-tint-2); border: 1px solid var(--border); border-radius: var(--radius-md); padding: 6px 18px; margin-top: 14px; }
.order-row { display: flex; justify-content: space-between; align-items: center; padding: 11px 0; font-size: 13.5px; color: var(--text-2); border-bottom: 1px dashed var(--border); }
.order-row:last-child { border-bottom: none; }
.order-row b { color: var(--text); }
.order-row.order-total b { color: var(--primary); font-size: 18px; }

/* 支付中 / 结果 */
.paying { text-align: center; padding: 30px 0 14px; }
.paying-spin {
  width: 46px; height: 46px; margin: 0 auto 20px; border-radius: 50%;
  border: 4px solid var(--primary-tint); border-top-color: var(--primary); animation: spin .9s linear infinite;
}
.pay-result { text-align: center; padding: 12px 0 6px; }
.pay-success-ico, .pay-fail-ico {
  width: 64px; height: 64px; margin: 0 auto 16px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center; font-size: 30px; font-weight: 800; color: #fff;
}
.pay-success-ico { background: var(--success); box-shadow: 0 0 0 10px rgba(46,158,107,.12); }
.pay-fail-ico { background: var(--danger); box-shadow: 0 0 0 10px rgba(201,79,79,.12); }
.pay-result .order-box { text-align: left; margin-bottom: 8px; }

/* 推送锁定卡片 */
.lock-card { text-align: center; padding: 34px 20px; border: 1.5px dashed var(--border-strong); background: var(--primary-tint-2); }
.lock-ico { font-size: 30px; margin-bottom: 8px; }
.lock-title { font-size: 15px; font-weight: 700; color: var(--primary-deep); }
.lock-desc { font-size: 12.5px; color: var(--text-2); margin: 8px 0 16px; }

/* 续费卡 */
.renew-card { padding: 20px 24px; margin-top: 18px; }

/* P1/P2 新增：升级 banner / 支付方式 / 订单状态 / 旗舰 */
.upgrade-banner {
  display: flex; align-items: center; gap: 14px;
  background: linear-gradient(120deg, var(--primary-dark), var(--primary) 60%, var(--primary-light));
  color: #fff; border-radius: var(--radius-lg); padding: 16px 22px; margin-bottom: 18px;
  box-shadow: var(--shadow-card);
}
.ub-icon { font-size: 26px; }
.ub-text { flex: 1; display: flex; flex-direction: column; }
.ub-text b { font-size: 15px; }
.ub-text span { font-size: 12.5px; opacity: .85; margin-top: 2px; }
#btnUpgradeBanner { background: #fff; color: var(--primary-deep); box-shadow: none; white-space: nowrap; }
#btnUpgradeBanner:hover { background: var(--primary-tint); }

.pay-methods { display: flex; gap: 10px; margin-top: 10px; }
.pay-method {
  flex: 1; display: flex; align-items: center; gap: 8px;
  padding: 12px 14px; border: 1.5px solid var(--border); border-radius: var(--radius-md);
  cursor: pointer; font-size: 13.5px; color: var(--text-2); transition: all .18s;
}
.pay-method:hover { border-color: var(--border-strong); }
.pay-method.sel { border-color: var(--primary); background: var(--primary-tint-2); color: var(--primary-deep); font-weight: 600; }
.pm-ico { font-size: 18px; }
.pm-check { margin-left: auto; color: var(--primary); font-weight: 700; }

.ms-pending { margin-top: 12px; padding: 10px 14px; background: #fdf7e8; border: 1px solid #f3e3bb; border-radius: var(--radius-sm); color: #8a6a1f; font-size: 12.5px; }
.ms-order-done { margin-top: 10px; padding: 8px 14px; background: #eaf7ef; border: 1px solid #cde9d8; border-radius: var(--radius-sm); color: var(--success); font-size: 12.5px; }
.ms-proplus-tag { display: inline-block; margin-top: 10px; padding: 4px 12px; background: linear-gradient(135deg, #f6d365, #fda085); color: #7a4a00; border-radius: 999px; font-size: 11.5px; font-weight: 700; }
.ms-tier.ms-proplus { background: linear-gradient(135deg, #f6d365, #fda085); color: #7a4a00; }
.member-status-proplus { border-color: #f6d365; box-shadow: 0 0 0 3px rgba(246,211,101,.18); }

@media (max-width: 900px) {
  .tier-compare { grid-template-columns: 1fr 1fr; }
}

/* ============================================================
   首页（官网 landing）
   ============================================================ */
#screen-home .main, .main { max-width: 1120px; }
.brand { cursor: pointer; }
.topbar-right { display: flex; align-items: center; gap: 10px; }

/* Hero 首屏（左文案 + 右视觉） */
.home-hero {
  background:
    radial-gradient(1200px 500px at 80% -20%, rgba(168, 108, 192, 0.22), transparent 60%),
    radial-gradient(900px 400px at 10% 110%, rgba(124, 58, 150, 0.14), transparent 60%),
    linear-gradient(180deg, #faf6fd 0%, var(--bg) 100%);
  margin: -36px -24px 0;
  padding: 80px 24px 64px;
}
.home-hero-inner {
  max-width: 1120px; margin: 0 auto;
  display: grid; grid-template-columns: 1.08fr .92fr; gap: 56px;
  align-items: center;
}
.home-hero-badge {
  display: inline-block; font-size: 12.5px; font-weight: 600; color: var(--primary-deep);
  background: #fff; border: 1px solid var(--border-strong);
  padding: 6px 18px; border-radius: 999px; margin-bottom: 24px;
}
.home-hero-title {
  font-family: var(--font-serif);
  font-size: 48px; line-height: 1.28; font-weight: 700;
  color: var(--primary-dark); letter-spacing: 1px;
}
.home-hero-title .hl-grad {
  background: linear-gradient(120deg, var(--primary) 10%, var(--primary-light) 90%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.home-hero-sub {
  font-size: 16px; color: var(--text-2); max-width: 470px; margin: 20px 0 30px; line-height: 1.9;
}
.home-hero-cta { display: flex; gap: 14px; margin-bottom: 12px; }
.home-hero-cta .btn { padding: 14px 34px; font-size: 15.5px; }
.home-hero-stats { display: flex; gap: 48px; margin-top: 36px; }
.hs-item { display: flex; flex-direction: column; }
.hs-item b { font-family: var(--font-serif); font-size: 30px; color: var(--primary-deep); font-weight: 700; }
.hs-item span { font-size: 12.5px; color: var(--text-3); margin-top: 4px; }

/* Hero 右侧视觉：漂浮情报卡 */
.home-hero-visual { position: relative; min-height: 400px; }
.hv-glow {
  position: absolute; inset: 6% 4%;
  background: radial-gradient(closest-side, rgba(168,108,192,.28), transparent 72%);
  filter: blur(6px);
}
.hv-card {
  position: absolute; width: 76%;
  background: #fff; border: 1px solid var(--border);
  border-radius: 16px; box-shadow: var(--shadow-float);
  padding: 16px 20px; animation: floaty 6s ease-in-out infinite;
}
.hv-card-1 { top: 14px; right: 0; }
.hv-card-2 { top: 148px; left: 0; animation-delay: -2s; }
.hv-card-3 { top: 282px; right: 6%; animation-delay: -4s; }
.hv-top { display: flex; justify-content: space-between; align-items: center; }
.hv-match { font-size: 11.5px; font-weight: 700; color: var(--primary); }
.hv-title { font-size: 14.5px; font-weight: 600; color: var(--text); margin-top: 10px; line-height: 1.5; }
.hv-src { font-size: 12px; color: var(--text-3); margin-top: 6px; }
@keyframes floaty { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-9px); } }

/* 功能栏目区 */
.home-sections { padding: 20px 0; }
.home-section { padding: 48px 0 12px; border-top: 1px solid var(--border); }
.home-section:first-of-type { border-top: none; }
.home-sec-head { text-align: center; margin-bottom: 28px; }
.home-sec-eyebrow {
  display: inline-block; font-size: 12px; font-weight: 700; letter-spacing: 2px;
  color: var(--primary); background: var(--primary-tint);
  padding: 4px 16px; border-radius: 999px; margin-bottom: 12px;
}
.home-sec-head h2 { font-family: var(--font-serif); font-size: 28px; color: var(--primary-dark); font-weight: 700; }
.home-sec-head p { font-size: 14px; color: var(--text-2); margin-top: 8px; }
.home-sec-body { max-width: 920px; margin: 0 auto; }
.home-sec-cta { text-align: center; margin-top: 20px; }

/* 首页订阅栏目 */
.home-sub-layout { display: grid; grid-template-columns: 200px 1fr; gap: 16px; align-items: start; }
.home-subject-panel { padding: 14px; max-height: 360px; overflow-y: auto; }
.home-subject-panel h3 { font-size: 13px; color: var(--text-3); font-weight: 600; padding: 4px 10px 10px; letter-spacing: 1px; }
.home-source-panel { padding: 6px 18px 14px; min-height: 360px; }

/* 首页身份拆解栏目 */
.home-profile-demo { padding: 24px 26px; }
.hpd-row { margin-bottom: 16px; }
.hpd-row label { display: block; font-size: 13px; font-weight: 600; color: var(--text); margin-bottom: 8px; }
.hpd-row textarea { min-height: 72px; resize: vertical; }
.hpd-actions { display: flex; justify-content: flex-end; }
.hpd-result { margin-top: 18px; padding-top: 16px; border-top: 1px dashed var(--border-strong); }
.hpd-done-tags { display: flex; flex-wrap: wrap; gap: 7px; margin-bottom: 10px; }
.hpd-done-line { font-size: 13px; color: var(--text-2); margin-bottom: 6px; }
.hpd-done-subs { font-size: 12.5px; color: var(--primary-deep); font-weight: 600; }

/* 首页推送栏目 */
.home-feed-list { display: flex; flex-direction: column; gap: 14px; }

/* 页脚 */
.home-footer {
  margin-top: 30px; padding: 28px 0 40px; border-top: 1px solid var(--border);
  display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
}
.home-footer-note { font-size: 12.5px; color: var(--text-3); }

/* 登录弹窗 */
.auth-modal { max-width: 460px; padding: 26px 28px; }
.auth-modal .auth-tabs { margin-bottom: 20px; }

@media (max-width: 900px) {
  .home-hero { padding: 52px 24px 48px; }
  .home-hero-inner { grid-template-columns: 1fr; gap: 40px; }
  .home-hero-title { font-size: 34px; }
  .home-hero-stats { gap: 28px; }
  .home-hero-visual { min-height: 300px; }
  .hv-card-1 { top: 0; right: 0; }
  .hv-card-2 { top: 110px; left: 0; }
  .hv-card-3 { top: 218px; right: 4%; }
  .home-sub-layout { grid-template-columns: 1fr; }
  .home-subject-panel { max-height: none; }
}
@media (max-width: 560px) {
  .home-hero-title { font-size: 28px; }
  .home-hero-cta .btn { padding: 12px 24px; font-size: 14px; }
  .home-hero-visual { min-height: 260px; }
  .hv-card { width: 88%; padding: 12px 16px; }
  .hv-title { font-size: 13px; }
  .hv-card-1 { top: 0; } .hv-card-2 { top: 102px; } .hv-card-3 { top: 200px; }
  .topbar-inner { gap: 12px; padding: 0 16px; }
  .brand-sub { display: none; }
  .main { padding: 24px 16px 60px; }
  .home-hero { margin: -24px -16px 0; }
}
