/* ===== 管理后台样式（沿用前台配色） ===== */
* { margin: 0; padding: 0; box-sizing: border-box; }
:root {
  --blue: #115199;
  --blue-deep: #2c4e70;
  --blue-light: #e8f0f8;
  --bg: #f2f5f8;
  --card: #ffffff;
  --card-alt: #f7f9fb;
  --line: #e3e8ee;
  --text: #33404f;
  --text-light: #6b7a8c;
  --red: #c0392b;
  --radius: 8px;
}
html, body { height: 100%; }
body {
  font-family: "Microsoft YaHei", "PingFang SC", "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 13.5px;
  line-height: 1.6;
}

/* ===== 按钮 / 输入 ===== */
.btn {
  border: none; border-radius: var(--radius);
  padding: 8px 18px; font-size: 13px; cursor: pointer;
  font-family: inherit;
}
.btn-primary { background: var(--blue); color: #fff; }
.btn-primary:hover { background: #0e4580; }
.btn-ghost { background: #e8edf2; color: var(--blue-deep); }
.btn-ghost:hover { background: #dbe2ea; }
.btn-danger { background: #fdecec; color: var(--red); }
.btn-danger:hover { background: #f9d9d9; }
.btn-sm { padding: 5px 12px; font-size: 12.5px; }
.btn-block { width: 100%; padding: 10px; font-size: 14px; }
.btn:disabled { opacity: .6; cursor: not-allowed; }

.input, select.input, textarea.input {
  width: 100%;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  font-size: 13px; font-family: inherit;
  background: #fff; color: var(--text);
  outline: none;
}
.input:focus { border-color: var(--blue); }
.field { margin-bottom: 10px; }
.field label { display: block; font-size: 12.5px; color: var(--blue-deep); margin-bottom: 4px; font-weight: bold; }
.field .hint { font-size: 11.5px; color: var(--text-light); margin-top: 3px; }

/* ===== 登录页 ===== */
.login-view {
  min-height: 100vh; display: flex; align-items: center; justify-content: center;
  background:
    radial-gradient(1200px 600px at 15% -10%, #e4edf6 0%, transparent 55%),
    radial-gradient(1000px 500px at 110% 110%, #d9e4f0 0%, transparent 50%),
    linear-gradient(135deg, #eef3f8 0%, #e2eaf3 100%);
  padding: 24px;
}
.login-shell {
  display: flex;
  width: 860px; max-width: 100%;
  min-height: 470px;
  background: var(--card);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(31, 61, 92, .18), 0 2px 8px rgba(31,61,92,.06);
}

/* 左侧品牌区 */
.login-aside {
  position: relative;
  width: 370px; flex-shrink: 0;
  background: linear-gradient(155deg, #0d437f 0%, #115199 55%, #1762ad 100%);
  color: #fff;
  display: flex; flex-direction: column;
  padding: 34px 32px 26px;
  overflow: hidden;
}
.la-pattern {
  position: absolute; inset: 0; pointer-events: none;
  background-image:
    radial-gradient(circle, rgba(255,255,255,.10) 1.2px, transparent 1.6px),
    radial-gradient(circle, rgba(255,255,255,.06) 1.2px, transparent 1.6px);
  background-size: 20px 20px, 20px 20px;
  background-position: 0 0, 10px 10px;
}
.la-pattern::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(13,67,127,0) 40%, rgba(13,67,127,.55) 100%);
}
.la-content { position: relative; z-index: 1; flex: 1; }
.la-brand { display: flex; align-items: center; gap: 10px; }
.la-mark {
  width: 38px; height: 38px; border-radius: 10px;
  background: rgba(255,255,255,.16);
  border: 1px solid rgba(255,255,255,.25);
  display: flex; align-items: center; justify-content: center;
  font-size: 19px; font-weight: bold;
}
.la-brand-name { font-size: 15px; font-weight: bold; letter-spacing: .5px; }
.la-headline { font-size: 25px; font-weight: bold; margin-top: 46px; letter-spacing: 1px; }
.la-desc { font-size: 13px; line-height: 1.9; color: rgba(255,255,255,.78); margin-top: 12px; }
.la-points { list-style: none; margin-top: 30px; }
.la-points li {
  display: flex; align-items: center; gap: 10px;
  font-size: 12.5px; color: rgba(255,255,255,.85);
  margin-bottom: 15px;
}
.la-points svg { width: 17px; height: 17px; flex-shrink: 0; color: #9ec8ee; }
.la-footer {
  position: relative; z-index: 1;
  font-size: 11.5px; color: rgba(255,255,255,.5); letter-spacing: .5px;
}

/* 右侧表单区 */
.login-main { flex: 1; display: flex; align-items: center; justify-content: center; padding: 32px 40px; }
.login-card { width: 100%; max-width: 310px; }
.login-card-head { display: flex; align-items: center; gap: 11px; margin-bottom: 26px; }
.lc-mark {
  width: 42px; height: 42px; background: var(--blue); color: #fff;
  border-radius: 11px; display: flex; align-items: center; justify-content: center;
  font-size: 20px; font-weight: bold; flex-shrink: 0;
  box-shadow: 0 4px 10px rgba(17,81,153,.28);
}
.login-title { font-size: 17px; font-weight: bold; color: var(--blue-deep); }
.login-sub { font-size: 12px; color: var(--text-light); margin-top: 2px; }

.login-field {
  position: relative; margin-bottom: 14px;
}
.lf-icon {
  position: absolute; left: 12px; top: 50%; transform: translateY(-50%);
  width: 17px; height: 17px; color: #94a3b3; pointer-events: none;
  display: flex;
}
.lf-icon svg { width: 17px; height: 17px; }
.login-field input {
  width: 100%;
  height: 42px;
  padding: 0 14px 0 39px;
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  font-size: 13.5px; font-family: inherit;
  background: #fbfcfd; color: var(--text);
  outline: none;
  transition: border-color .18s, box-shadow .18s, background .18s;
}
.login-field input::placeholder { color: #a4b0be; }
.login-field input:focus {
  border-color: var(--blue);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(17,81,153,.12);
}
.login-field input:-webkit-autofill {
  -webkit-box-shadow: 0 0 0 30px #fff inset;
  -webkit-text-fill-color: var(--text);
}
.login-error { color: var(--red); font-size: 12.5px; min-height: 18px; margin: 2px 0 8px; }
.login-error:not(:empty) {
  background: #fdecec; border-radius: 6px; padding: 5px 10px;
}
.login-btn {
  width: 100%; height: 42px; margin-top: 4px;
  border: none; border-radius: var(--radius);
  background: linear-gradient(180deg, #1860a8 0%, #115199 100%);
  color: #fff; font-size: 14.5px; letter-spacing: 4px; text-indent: 4px;
  font-family: inherit; cursor: pointer;
  display: flex; align-items: center; justify-content: center; gap: 8px;
  box-shadow: 0 4px 12px rgba(17,81,153,.25);
  transition: transform .15s, box-shadow .15s, filter .15s;
}
.login-btn:hover { filter: brightness(1.08); box-shadow: 0 6px 16px rgba(17,81,153,.32); }
.login-btn:active { transform: translateY(1px); box-shadow: 0 2px 6px rgba(17,81,153,.25); }
.login-btn:disabled { opacity: .65; cursor: not-allowed; filter: none; }
.lb-arrow { width: 16px; height: 16px; transition: transform .18s; }
.login-btn:hover .lb-arrow { transform: translateX(3px); }
.login-back {
  display: flex; align-items: center; justify-content: center; gap: 5px;
  margin-top: 18px; font-size: 12.5px; color: var(--text-light); text-decoration: none;
  transition: color .15s;
}
.login-back svg { width: 14px; height: 14px; }
.login-back:hover { color: var(--blue); }

/* 窄屏：隐藏品牌区，表单居中 */
@media (max-width: 760px) {
  .login-shell { width: 380px; min-height: 0; }
  .login-aside { display: none; }
  .login-main { padding: 34px 28px; }
}

/* ===== 后台框架 ===== */
.admin { height: 100vh; display: flex; flex-direction: column; overflow: hidden; }
.admin-topbar {
  height: 50px; background: var(--card); border-bottom: 1px solid var(--line);
  display: flex; align-items: center; padding: 0 14px; gap: 18px; flex-shrink: 0;
}
.at-brand { display: flex; align-items: center; gap: 8px; }
.at-mark {
  width: 28px; height: 28px; background: var(--blue); color: #fff;
  border-radius: 7px; display: flex; align-items: center; justify-content: center;
  font-size: 14px; font-weight: bold;
}
.at-name { font-size: 14px; font-weight: bold; color: var(--blue-deep); white-space: nowrap; }
.at-tabs { display: flex; gap: 2px; flex: 1; }
.at-tab {
  padding: 6px 16px; font-size: 13.5px; color: var(--text-light);
  cursor: pointer; border-radius: var(--radius); user-select: none;
}
.at-tab:hover { background: var(--blue-light); }
.at-tab.active { color: var(--blue); font-weight: bold; background: var(--blue-light); }
.at-right { display: flex; align-items: center; gap: 10px; }
.at-user { font-size: 12.5px; color: var(--text-light); }
.at-link { font-size: 12.5px; color: var(--blue); text-decoration: none; }

.tab-panel { display: none; flex: 1; overflow: hidden; }
.tab-panel.active { display: flex; }
#panel-glossary.active, #panel-gallery.active { display: block; overflow-y: auto; }

/* ===== 内容管理：左树 + 右编辑 ===== */
.content-tree {
  width: 260px; flex-shrink: 0; background: var(--card);
  border-right: 1px solid var(--line);
  display: flex; flex-direction: column;
}
.tree-toolbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 12px; border-bottom: 1px solid var(--line); flex-shrink: 0;
}
.tree-title { font-size: 13px; font-weight: bold; color: var(--blue-deep); }
.icon-add {
  background: none; border: 1px solid var(--blue); color: var(--blue);
  border-radius: var(--radius); padding: 3px 9px; font-size: 12px;
  cursor: pointer; font-family: inherit;
}
.icon-add:hover { background: var(--blue-light); }
.tree-body { flex: 1; overflow-y: auto; padding: 6px 8px; }

.tree-module { margin-bottom: 2px; }
.tree-mod-head {
  display: flex; align-items: center; gap: 6px;
  padding: 7px 8px; border-radius: 6px; cursor: pointer;
  font-size: 13px; font-weight: bold; color: var(--blue-deep);
}
.tree-mod-head:hover { background: var(--card-alt); }
.tree-mod-head .tm-arrow { font-size: 9px; color: var(--text-light); transition: transform .2s; width: 10px; }
.tree-module.open .tm-arrow { transform: rotate(90deg); }
.tree-mod-head .tm-icon { font-size: 13px; }
.tree-mod-head .tm-name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tree-mod-actions { display: none; gap: 2px; }
.tree-mod-head:hover .tree-mod-actions { display: flex; }
.tm-act {
  border: none; background: none; cursor: pointer; font-size: 12px;
  color: var(--text-light); padding: 0 3px; line-height: 1;
}
.tm-act:hover { color: var(--blue); }
.tm-act.del:hover { color: var(--red); }

.tree-sections { margin-left: 16px; border-left: 1px dashed var(--line); padding-left: 4px; display: none; }
.tree-module.open .tree-sections { display: block; }
.tree-sec {
  display: flex; align-items: center; gap: 4px;
  padding: 5px 8px; border-radius: 6px; font-size: 12.5px;
  color: var(--text-light); cursor: pointer;
}
.tree-sec:hover { background: var(--card-alt); color: var(--blue); }
.tree-sec.active { background: var(--blue-light); color: var(--blue); font-weight: bold; }
.tree-sec .ts-name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tree-sec .ts-del { display: none; border: none; background: none; cursor: pointer; color: var(--text-light); font-size: 12px; }
.tree-sec:hover .ts-del { display: inline; }
.tree-sec .ts-del:hover { color: var(--red); }
.tree-add-sec {
  padding: 5px 8px; font-size: 12px; color: var(--blue);
  cursor: pointer; border-radius: 6px;
}
.tree-add-sec:hover { background: var(--blue-light); }

/* 编辑区 */
.content-editor { flex: 1; min-height: 0; display: flex; flex-direction: column; overflow: hidden; background: var(--bg); }

/* ===== 编辑器：自适应高度布局 ===== */
.ed-wrap { flex: 1; min-height: 0; display: flex; flex-direction: column; gap: 10px; padding: 14px; overflow: hidden; }
.ed-meta-card { flex-shrink: 0; margin: 0; padding: 12px 16px; }
.ed-main-card { flex: 1; min-height: 0; margin: 0; padding: 12px 16px; display: flex; flex-direction: column; }
.ed-mode-bar { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; flex-shrink: 0; }
.seg { display: inline-flex; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; }
.seg-btn {
  border: none; background: var(--card); color: var(--text-light);
  font-family: inherit; font-size: 12.5px; padding: 5px 16px; cursor: pointer;
}
.seg-btn + .seg-btn { border-left: 1px solid var(--line); }
.seg-btn.active { background: var(--blue); color: #fff; font-weight: bold; }
.ed-status { font-size: 12px; color: var(--text-light); }
.ed-status.dirty { color: #d97c2b; font-weight: bold; }
.ed-status.saved { color: #1f7a4d; }
.ed-status.error { color: var(--red); }
.ed-canvas { flex: 1; min-height: 160px; display: flex; flex-direction: column; }
.save-kbd {
  font-size: 10.5px; font-weight: normal; margin-left: 8px;
  background: rgba(255,255,255,.28); border-radius: 4px; padding: 1px 6px;
}
.editor-card {
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 14px 16px; margin-bottom: 12px;
}
.editor-meta { display: flex; gap: 10px; flex-wrap: wrap; }
.editor-meta .field { flex: 1; min-width: 140px; margin-bottom: 0; }
.editor-toolbar {
  display: flex; gap: 4px; flex-wrap: wrap; flex-shrink: 0;
  padding: 8px; border: 1px solid var(--line); border-bottom: none;
  border-radius: var(--radius) var(--radius) 0 0; background: var(--card-alt);
}
.tb-btn {
  border: 1px solid var(--line); background: #fff; border-radius: 5px;
  padding: 4px 9px; font-size: 12.5px; cursor: pointer; color: var(--blue-deep);
  font-family: inherit; min-width: 30px;
}
.tb-btn:hover { background: var(--blue-light); border-color: var(--blue); }
.tb-sep { width: 1px; background: var(--line); margin: 2px 4px; }
.editor-area {
  flex: 1; min-height: 0; overflow-y: auto;
  border: 1px solid var(--line); border-radius: 0 0 var(--radius) var(--radius);
  padding: 12px 14px; background: #fff; outline: none; font-size: 13.5px; line-height: 1.8;
}
.editor-area img { max-width: 100%; border-radius: 6px; margin: 6px 0; }
.editor-area:focus { border-color: var(--blue); }
.editor-area h2 { font-size: 18px; color: var(--blue-deep); margin: 10px 0 8px; border-bottom: 2px solid var(--blue); display: inline-block; padding-bottom: 6px; }
.editor-area h3 { font-size: 15px; color: var(--blue); margin: 12px 0 6px; padding-left: 8px; border-left: 3px solid var(--blue); }
.editor-area p { margin-bottom: 8px; }
.editor-area ul, .editor-area ol { margin: 0 0 8px 22px; }
.editor-area table { width: 100%; border-collapse: collapse; margin: 8px 0; }
.editor-area th { background: var(--blue); color: #fff; padding: 7px 10px; text-align: left; font-size: 12.5px; }
.editor-area td { border: 1px solid var(--line); padding: 7px 10px; font-size: 12.5px; }
.editor-area .tip { border-radius: 6px; padding: 8px 11px; margin: 8px 0; font-size: 12.5px; border-left: 3px solid; }
.editor-area .tip.info { background: #eef5fb; border-color: var(--blue); color: var(--blue-deep); }
.editor-area .tip.warn { background: #fdf3ec; border-color: #d97c2b; color: #9a5410; }
.editor-area .tip.danger { background: #fdecec; border-color: var(--red); color: #8f2820; }
.source-area {
  flex: 1; min-height: 0; border: 1px solid var(--line);
  border-radius: 0 0 var(--radius) var(--radius);
  padding: 10px; font-family: Consolas, "Courier New", monospace;
  font-size: 12.5px; line-height: 1.6; outline: none; resize: none;
  background: #fff;
}
.editor-actions { display: flex; gap: 10px; margin-top: 12px; flex-shrink: 0; }

/* ===== 高级设置折叠区 ===== */
.adv-toggle {
  margin-top: 10px; font-size: 12.5px; color: var(--text-light);
  cursor: pointer; user-select: none; display: flex; align-items: center; gap: 6px;
}
.adv-toggle:hover { color: var(--blue); }
.adv-arrow { font-size: 9px; display: inline-block; transition: transform .2s; }
.adv-toggle.open .adv-arrow { transform: rotate(90deg); }
.adv-body { display: none; margin-top: 10px; }
.adv-body.open { display: block; }
.ed-adv-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
.adv-warn { font-size: 11.5px; color: #b03a2e; margin-top: 4px; line-height: 1.5; }

/* ===== 前台样式预览 ===== */
.pv-wrap {
  flex: 1; min-height: 0; overflow-y: auto;
  border: 1px solid var(--line); border-radius: 0 0 var(--radius) var(--radius);
  background: #fff; padding: 20px 26px;
}
.pv-article { font-size: 14px; color: var(--text); max-width: 820px; margin: 0 auto; }
.pv-article h2 {
  font-size: 19px; color: var(--blue-deep); margin: 2px 0 14px;
  padding-bottom: 8px; border-bottom: 2px solid var(--blue); display: inline-block;
}
.pv-article h3 { font-size: 15.5px; color: var(--blue); margin: 16px 0 8px; padding-left: 8px; border-left: 3px solid var(--blue); }
.pv-article p { margin-bottom: 10px; line-height: 1.85; }
.pv-article ul, .pv-article ol { margin: 0 0 10px 22px; }
.pv-article li { margin-bottom: 5px; line-height: 1.8; }
.pv-article strong { color: var(--blue-deep); }
.pv-article .lead { background: var(--blue-light); border-radius: var(--radius); padding: 12px 14px; margin-bottom: 12px; line-height: 1.8; }
.pv-article .tip { border-radius: 6px; padding: 9px 12px; margin: 10px 0; font-size: 13px; border-left: 3px solid; line-height: 1.7; }
.pv-article .tip.info { background: #eef5fb; border-color: var(--blue); color: var(--blue-deep); }
.pv-article .tip.warn { background: #fdf3ec; border-color: #d97c2b; color: #9a5410; }
.pv-article .tip.danger { background: #fdecec; border-color: var(--red); color: #8f2820; }
.pv-article table { width: 100%; border-collapse: collapse; margin: 10px 0; }
.pv-article th { background: var(--blue); color: #fff; padding: 8px 10px; text-align: left; font-size: 13px; }
.pv-article td { border: 1px solid var(--line); padding: 8px 10px; font-size: 13px; }
.pv-article img { max-width: 100%; border-radius: 6px; margin: 6px 0; }
.pv-article .table-wrap { overflow-x: auto; }
.preview-box {
  border: 1px solid var(--line); border-radius: var(--radius);
  background: #fff; padding: 14px 18px; margin-top: 12px;
}
.preview-box h2 { font-size: 18px; color: var(--blue-deep); margin-bottom: 10px; padding-bottom: 8px; border-bottom: 2px solid var(--blue); display: inline-block; }

/* 空状态 */
.empty-state { text-align: center; padding: 80px 20px; color: var(--text-light); }
.empty-icon { font-size: 46px; margin-bottom: 12px; }
.empty-text { font-size: 14px; }
.empty-sub { font-size: 12.5px; margin-top: 4px; }

/* ===== 列表页（术语/图谱） ===== */
.list-page { padding: 14px; max-width: 1200px; margin: 0 auto; width: 100%; }
.list-toolbar { display: flex; gap: 10px; margin-bottom: 12px; align-items: center; }
.search-input { max-width: 260px; }
.table-wrap {
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); overflow: hidden;
}
.data-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.data-table th {
  background: var(--blue); color: #fff; text-align: left;
  padding: 9px 12px; font-weight: bold; white-space: nowrap;
}
.data-table td { padding: 8px 12px; border-top: 1px solid var(--line); vertical-align: top; }
.data-table tr:nth-child(even) td { background: var(--card-alt); }
.data-table .cell-desc { color: var(--text); max-width: 420px; }
.data-table .cell-actions { white-space: nowrap; }
.link-btn {
  border: none; background: none; cursor: pointer; font-size: 12.5px;
  color: var(--blue); padding: 0 4px; font-family: inherit;
}
.link-btn.danger { color: var(--red); }
.cat-tag {
  display: inline-block; font-size: 11.5px; color: var(--blue);
  background: var(--blue-light); padding: 1px 9px; border-radius: 10px;
}

/* 图谱管理网格 */
.gallery-admin-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px; }
.ga-cat-card {
  grid-column: 1 / -1; background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 10px 14px;
  display: flex; align-items: center; gap: 10px; margin-top: 4px;
}
.ga-cat-name { font-weight: bold; color: var(--blue-deep); font-size: 13.5px; }
.ga-cat-count { font-size: 12px; color: var(--text-light); }
.ga-cat-ops { margin-left: auto; display: flex; gap: 6px; }
.ga-card {
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); overflow: hidden;
}
.ga-thumb { aspect-ratio: 4/3; background: #edf1f5; }
.ga-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ga-info { padding: 8px 10px; }
.ga-title { font-size: 13px; font-weight: bold; color: var(--blue-deep); margin-bottom: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ga-desc { font-size: 11.5px; color: var(--text-light); margin-bottom: 6px; height: 32px; overflow: hidden; }
.ga-ops { display: flex; gap: 8px; }

/* ===== 弹窗 ===== */
.modal-mask {
  display: none; position: fixed; inset: 0; z-index: 200;
  background: rgba(26,35,46,.45); align-items: flex-start; justify-content: center;
  padding: 60px 16px 20px; overflow-y: auto;
}
.modal-mask.show { display: flex; }
.modal {
  background: var(--card); border-radius: 10px; width: 100%;
  max-width: 480px; box-shadow: 0 10px 40px rgba(20,40,60,.25);
}
.modal.wide { max-width: 640px; }
.modal-body { padding: 16px; }
.modal-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 14px; }
.form-textarea { min-height: 90px; resize: vertical; }

/* ===== toast ===== */
.toast-box { position: fixed; top: 18px; left: 50%; transform: translateX(-50%); z-index: 300; display: flex; flex-direction: column; gap: 8px; align-items: center; }
.toast {
  background: #2c3a4a; color: #fff; font-size: 13px;
  padding: 9px 20px; border-radius: 20px; box-shadow: 0 4px 16px rgba(0,0,0,.2);
  animation: toastIn .2s ease;
}
.toast.success { background: #1f7a4d; }
.toast.error { background: #b03a2e; }
@keyframes toastIn { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: translateY(0); } }

/* ===== 左侧树：搜索 + 拖拽 ===== */
.tree-search {
  position: relative; padding: 8px 10px 2px; flex-shrink: 0;
}
.tree-search svg {
  position: absolute; left: 20px; top: 50%; transform: translateY(-50%);
  width: 13px; height: 13px; color: var(--text-light); pointer-events: none;
}
.tree-search input {
  width: 100%; padding: 6px 10px 6px 28px; font-size: 12.5px;
  border: 1px solid var(--line); border-radius: 6px; font-family: inherit;
  background: var(--card); color: var(--text); outline: none;
}
.tree-search input:focus { border-color: var(--blue); }
.tree-empty { padding: 24px 12px; text-align: center; font-size: 12px; color: var(--text-light); line-height: 1.7; }
.tree-sec { position: relative; }
.ts-grip {
  cursor: grab; color: #c4ced8; font-size: 13px; width: 12px; flex-shrink: 0;
  user-select: none; text-align: center; line-height: 1;
}
.ts-grip:active { cursor: grabbing; }
.tree-sec.dragging { opacity: .35; }
.tree-sec.drop-before { box-shadow: inset 0 2px 0 var(--blue); }
.tree-sec.drop-after { box-shadow: inset 0 -2px 0 var(--blue); }

/* ===== 骨架屏 ===== */
.skeleton-card {
  background: var(--card); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 16px 18px; flex-shrink: 0;
}
.sk-main { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.sk-line {
  height: 13px; border-radius: 5px; margin: 10px 0;
  background: linear-gradient(90deg, #edf1f5 25%, #f7f9fb 37%, #edf1f5 63%);
  background-size: 400% 100%; animation: skShimmer 1.4s ease infinite;
}
.sk-line.w20 { width: 20%; } .sk-line.w45 { width: 45%; }
.sk-line.w62 { width: 62%; } .sk-line.w70 { width: 70%; }
.sk-line.w86 { width: 86%; } .sk-line.w88 { width: 88%; }
.sk-line.w90 { width: 90%; } .sk-line.w93 { width: 93%; }
.sk-toolbar { height: 32px; border-radius: 6px; margin-bottom: 14px;
  background: linear-gradient(90deg, #edf1f5 25%, #f7f9fb 37%, #edf1f5 63%);
  background-size: 400% 100%; animation: skShimmer 1.4s ease infinite;
}
@keyframes skShimmer { 0% { background-position: 100% 0; } 100% { background-position: 0 0; } }

/* ===== 未保存确认弹窗 / 图片弹窗 ===== */
.guard-icon { font-size: 34px; text-align: center; margin-bottom: 8px; }
.guard-title { font-size: 15px; font-weight: bold; color: var(--text); text-align: center; }
.guard-text { font-size: 13px; color: var(--text-light); text-align: center; margin: 8px 0 18px; line-height: 1.7; }
.modal-or { text-align: center; color: var(--text-light); font-size: 12px; margin: 4px 0 10px; }

/* ===== 响应式 ===== */
@media (max-width: 768px) {
  .at-name, .at-user { display: none; }
  .content-tree { width: 200px; }
  .at-tabs { gap: 0; }
  .at-tab { padding: 6px 10px; font-size: 12.5px; }
  .ed-adv-grid { grid-template-columns: 1fr; }
  .seg-btn { padding: 5px 12px; }
}

/* ===== 行业资讯 ===== */
.news-tool-tip { font-size: 12px; color: var(--text-light); margin-left: 10px; }
.news-subtabs { display: flex; gap: 4px; background: #e8edf2; padding: 3px; border-radius: 8px; }
.news-sub {
  border: none; background: transparent; cursor: pointer; font-family: inherit;
  font-size: 12.5px; color: var(--text-light); padding: 5px 14px; border-radius: 6px;
  display: flex; align-items: center; gap: 6px;
}
.news-sub.active { background: #fff; color: var(--blue); font-weight: bold;
  box-shadow: 0 1px 3px rgba(0,0,0,.08); }
.news-badge {
  min-width: 18px; height: 18px; line-height: 18px; padding: 0 5px;
  border-radius: 9px; background: #d4dce5; color: #fff;
  font-size: 11px; text-align: center; font-weight: normal;
}
.news-sub.active .news-badge { background: var(--blue); }

.news-list { display: flex; flex-direction: column; gap: 10px; margin-top: 14px; }
.news-card {
  display: flex; justify-content: space-between; gap: 16px;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 14px 16px; transition: border-color .15s, box-shadow .15s;
}
.news-card:hover { border-color: #c6d4e4; box-shadow: 0 2px 8px rgba(17,81,153,.06); }
.news-card-main { min-width: 0; flex: 1; }
.news-card-link {
  font-size: 14px; font-weight: bold; color: var(--blue-deep);
  text-decoration: none; line-height: 1.5;
}
.news-card-link:hover { color: var(--blue); text-decoration: underline; }
.news-ext { font-size: 12px; font-weight: normal; color: var(--text-light); }
.news-card-summary {
  font-size: 12.5px; color: var(--text-light); line-height: 1.7;
  margin: 6px 0 8px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.news-card-meta { display: flex; flex-wrap: wrap; gap: 12px; font-size: 12px; color: var(--text-light); }
.news-tag { background: var(--blue-light); color: var(--blue); padding: 1px 8px; border-radius: 4px; }
.news-card-ops { display: flex; gap: 6px; align-items: flex-start; flex-shrink: 0; }
.news-empty, .news-loading {
  text-align: center; color: var(--text-light); font-size: 13px;
  padding: 60px 0; background: var(--card); border: 1px dashed var(--line);
  border-radius: var(--radius); margin-top: 14px;
}
.news-pager { display: flex; align-items: center; justify-content: center; gap: 14px; margin-top: 18px; }
.news-page-info { font-size: 12.5px; color: var(--text-light); }

/* 关键词管理弹窗 */
.kw-add-row { display: flex; gap: 8px; margin-bottom: 14px; }
.kw-add-row .input { flex: 1; }
.kw-list { display: flex; flex-wrap: wrap; gap: 8px; min-height: 48px;
  padding: 10px; background: var(--card-alt); border: 1px solid var(--line); border-radius: 6px; }
.kw-empty { color: var(--text-light); font-size: 12.5px; }
.kw-chip {
  display: inline-flex; align-items: center; gap: 4px;
  background: #fff; border: 1px solid #c6d4e4; color: var(--blue-deep);
  font-size: 12.5px; padding: 4px 8px 4px 12px; border-radius: 20px;
}
.kw-del {
  border: none; background: #e3e9f0; color: var(--text-light); cursor: pointer;
  width: 18px; height: 18px; border-radius: 50%; font-size: 13px; line-height: 1;
  display: inline-flex; align-items: center; justify-content: center; padding: 0;
}
.kw-del:hover { background: var(--red); color: #fff; }
.kw-tip { font-size: 12px; color: var(--text-light); margin: 10px 0 4px; line-height: 1.6; }
.form-label { display: block; font-size: 12.5px; font-weight: bold; color: var(--blue-deep); margin-bottom: 5px; }
.ne-textarea { width: 100%; min-height: 120px; resize: vertical; font-family: inherit; line-height: 1.7; }

@media (max-width: 768px) {
  .news-card { flex-direction: column; gap: 10px; }
  .news-card-ops { flex-wrap: wrap; }
  .news-subtabs { width: 100%; justify-content: center; }
}
