/* Fonts */
  /* Keyframes */
  @keyframes fadeIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); }}
  .fade-in { will-change: opacity; }

  /* Root Body */
  * { margin: 0; padding: 0; box-sizing: border-box; }
  [data-theme="dark"] {
  .logo-img { filter: brightness(0) invert(1); }
  .kb-card-title svg, .rec-cat-label svg, .ai-guide-section-icon svg, .model-series-icon svg { fill: var(--text-primary); }
  .ai-guide-card svg, .ai-guide-detail svg, .cobuild-header > svg { fill: var(--text-primary); }
  .nav-tab.active { border-color: var(--accent); border-bottom-color: var(--accent); }
  .nav-tab:hover { border-color: #EDEDEF; }
  .rec-tag:hover, .rec-tag.selected { border-color: var(--accent); }
  .rec-tag.selected { background: var(--accent); color: var(--bg-primary); }
  .search-box, .search-box:focus { border-color: #EDEDEF; }
  .btn-primary { background: var(--accent); color: var(--bg-primary); border-color: var(--accent); }
  .btn-primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: var(--bg-primary); }
  .btn-sm { background: var(--accent); border-color: var(--accent); color: var(--bg-primary); }
  .btn-sm:hover { background: var(--accent-hover); border-color: var(--accent-hover); }}
  body { font-family: -apple-system, BlinkMacSystemFont, 'PingFang SC', 'Microsoft YaHei', 'Segoe UI', sans-serif; background: var(--bg-primary); color: var(--text-primary); line-height: 1.6; font-size:14px; -webkit-font-smoothing: antialiased; transition: background 0.3s, color 0.3s; margin: 0; background-image: radial-gradient(circle, var(--border-light) 0.5px, transparent 0.5px); background-size: 3px 3px; background-repeat: repeat; }

  .btn { padding: 8px 18px; border-radius: 10px; font-size: 14px; font-weight: 600; border: 2px solid var(--border); transition: all 0.2s ease; text-decoration: none; display: inline-flex; align-items: center; justify-content: center; gap: 6px; cursor: pointer; text-align: center; }
  .btn-ghost { background: var(--input-bg); color: var(--text-primary); border: 2px solid var(--border); }
  .btn-ghost:hover { background: var(--accent-light); color: var(--text-primary); border-color: var(--accent); }
  [data-theme="light"] .btn-primary { background: #3D3028; color: var(--bg-primary); border-color: #3D3028; transition: all 0.2s ease; }
  [data-theme="light"] .btn-primary:hover { background: #2A1F18; border-color: #2A1F18; transform: translate(-1px,-1px); }
  .btn-secondary { background: var(--bg-tertiary); color: var(--text-primary); border: 2px solid var(--border); }
  .btn-secondary:hover { border-color: var(--text-tertiary); }
  .btn-copy { padding: 8px 18px; border-radius: 10px; font-size: 14px; font-weight: 600; border: 2px solid var(--border); background: var(--input-bg); color: var(--text-secondary); transition: all 0.15s; display: inline-flex; align-items: center; gap: 5px; }
  .btn-copy:hover { border-color: var(--accent); color: var(--accent); background: var(--accent-light); }
  [data-theme="light"] .btn-sm { padding: 5px 12px; border-radius: 8px; font-size: 12px; font-weight: 600; border: 2px solid #3D3028; transition: all 0.15s; cursor: pointer; display: inline-flex; align-items: center; gap: 4px; background: #3D3028; color: var(--bg-primary); }
  [data-theme="light"] .btn-sm:hover { background: #2A1F18; border-color: #2A1F18; transform: translate(-1px,-1px); }
  .nav-signup { padding: 7px 20px; }

  /* Page */
  .page { transition: background 0.25s ease, color 0.2s ease; display: none; width: 90%; max-width: 1600px; margin: 0 auto; padding: 24px 0 48px; position: relative; z-index: 1; }
  .page.active { display: block; animation: fadeIn 0.3s ease; will-change: transform; }

  /* Hero */
  .workstation-hero { text-align: left; padding: 32px 0 28px; }
  .workstation-hero h1 { font-size: 42px; font-weight: 900; margin-bottom: 10px; letter-spacing: 0; font-family: 'PingFang SC', 'Microsoft YaHei', 'SimHei', sans-serif; color: var(--text-primary); line-height: 1.3; }
  .workstation-hero p { color: var(--text-secondary); font-size: 16px; max-width: 100%; margin: 0; line-height: 1.6; }
  .banner-svg { width: 100%; height: auto; display: block; margin-bottom: 24px; }
  @media (max-width: 768px) { .banner-svg { margin-bottom: 16px; } }

  /* Mode Switch */
  .editor-mode-switch { display: flex; justify-content: center; margin-bottom: 16px; }
  .editor-mode-switch .mode-btn { padding: 8px 24px; border: 2px solid var(--border); background: var(--input-bg); font-size: 14px; font-weight: 600; color: var(--text-primary); border-radius: 10px; transition: all 0.15s; display: flex; align-items: center; gap: 8px; margin: 0 4px; }
  .mode-btn svg { width: 18px; height: 18px; }
  .editor-mode-switch .mode-btn.active { background: var(--accent); color: var(--bg-primary); border-color: var(--accent); }
  [data-theme="light"] .editor-mode-switch .mode-btn.active { background: #3D3028; color: var(--bg-primary); border-color: #3D3028; }
  .editor-mode-switch .mode-btn:hover:not(.active) { border-color: var(--accent); color: var(--accent); background: var(--accent-light); }

  /* Editor */
  .editor-container { display: flex; flex-direction: column; gap: 16px; margin-bottom: 16px; }
  .editor-card { transition: background 0.25s ease, border-color 0.2s ease, box-shadow 0.2s ease; background: var(--input-bg); border: 2px solid var(--border); border-radius: 10px; width: 100%; box-sizing: border-box; }
  .editor-card:hover { border-color: var(--accent); box-shadow: var(--card-shadow-hover); transform: translateY(-1px); }
  .editor-header { display: flex; align-items: center; justify-content: flex-start; padding: 14px 20px; border-bottom: 2px solid var(--border); }
  .editor-header-left { display: flex; align-items: center; gap: 8px; font-size: 15px; font-weight: 600; color: var(--text-primary); }
  .editor-body { padding: 20px; }
  .editor-section { padding: 14px 16px; min-width: 0; }
  .editor-section:not(:last-child) { border-bottom: 2px solid var(--border-light); }
  .editor-section-label { font-size:12px; font-weight: 600; color: var(--text-tertiary); text-transform: uppercase; letter-spacing: 0.5px; display: block; margin-bottom: 8px; }
  .editor-header-alt { border-bottom: none; padding: 12px 16px; }
  .editor-section-stack { display: flex; flex-direction: column; gap: 4px; }
  .editor-body-flush { padding: 0; }

  /* Category */
  /* 词条推荐 */
 .rec-cat-section { padding: 10px 12px; border-bottom: 2px solid var(--border-light); min-width: 0; }
  .rec-cat-section:last-child { border-bottom: none; }
  .rec-cat-label { font-size:14px; font-weight: 600; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 0.04em; padding: 4px 4px 8px; display: flex; align-items: center; gap: 6px; }
  .rec-tags { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 5px; padding: 2px 2px 4px; overflow: hidden; min-width: 0; }
  .rec-tag { position: relative; display: flex; align-items: center; justify-content: center; padding: 6px 12px; border-radius: 10px; border: 2px solid var(--border-light); background: var(--input-bg); font-size:14px; font-weight: 500; color: var(--text-primary); transition: all 0.15s; text-align: center; white-space: pre-line; cursor: pointer; }
  .rec-tag:hover { border-color: var(--accent); background: var(--accent-light); color: var(--accent); }
  .rec-tag.selected { background: var(--accent); border-color: var(--accent); color: var(--bg-primary); font-weight: 500; box-shadow: var(--card-shadow); }
  .rec-tag.selected::before { content: '✓ '; font-size: 12px; }
  .rec-tag.disabled { opacity: 0.35; pointer-events: none; cursor: not-allowed; }

  .tag-tip-bar { position: fixed; background: var(--tooltip-bg); color: var(--tooltip-text); padding: 8px 14px; border-radius: 8px; font-size: 12px; line-height: 1.6; display: none; border: 2px solid var(--border-light); z-index: 200; max-width: 320px; box-shadow: var(--card-shadow); pointer-events: none; }
  .tag-tip-bar.active { display: block; }

  /* Formula */
  /* Formula chips */
 .formula-chips { display: flex; align-items: center; gap: 6px; padding: 8px 16px; background: var(--bg-primary); border: 2px solid var(--border); border-radius:8px; margin-bottom: 8px; font-size: 14px; flex-wrap: wrap; width: 100%; box-sizing: border-box; min-height: 42px; color-scheme: light; transition: all 0.15s; position: relative; }
  .formula-chips:hover { border-color: var(--accent); box-shadow: var(--card-shadow-hover); transform: translateY(-1px); }
  .formula-label { font-weight: 600; color: var(--text-primary); white-space: nowrap; font-size: 15px; flex-shrink: 0; flex-basis: 100%; margin-bottom: 4px; }
  .formula-chip { display: inline-flex; align-items: center; gap: 4px; padding: 4px 10px; border-radius: 10px; border: 2px solid var(--border-light); background: var(--bg-primary); color: var(--text-secondary); font-size: 14px; font-weight: 500; white-space: nowrap; cursor: grab; transition: all 0.15s;-webkit-user-select: none; }
  .formula-chip:active { cursor: grabbing; }
  .formula-chip:hover { border-color: var(--accent); }
  .formula-chip.dragging { opacity: 0.4; }
  .formula-chip.drag-over { border-color: var(--accent); background: var(--accent-light); }
  .formula-chip.user-fill { border-color: var(--accent); color: var(--accent); background: var(--accent-light); font-weight: 500; cursor: grab; }
  .formula-chip .chip-del { display: inline-flex; align-items: center; justify-content: center; width: 14px; height: 14px; color: var(--text-tertiary); transition: color 0.15s; flex-shrink: 0; cursor: pointer; }
  .formula-chip .chip-del:hover { color: var(--coral); }
  .formula-restore-btn { display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 28px; border-radius: 8px; border: 2px solid var(--border); background: var(--bg-primary); color: var(--text-tertiary); flex-shrink: 0; }
  .formula-restore-btn:hover { border-color: var(--accent); color: var(--accent); background: var(--accent-light); }
  .formula-drop-indicator { width: 3px; align-self: stretch; min-height: 28px; background: var(--accent); border-radius: 2px; flex-shrink: 0; transition: opacity 0.1s; box-shadow: 0 0 6px var(--accent); }
  .formula-add-btn { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 28px; height: 28px; border-radius: 8px; border: 2px solid var(--border); background: var(--bg-primary); color: var(--text-tertiary); flex-shrink: 0; }
  .formula-add-btn:hover { border-color: var(--accent); color: var(--accent); background: var(--accent-light); }
  .formula-add-menu { display: none; position: absolute; top: calc(100% + 6px); right: 0; min-width: 160px; background: var(--bg-primary); border: 2px solid var(--border); border-radius: 8px; box-shadow: var(--dropdown-shadow); z-index: 100; padding: 4px 0; }
  .formula-add-menu.open { display: block; }
  .formula-add-item { padding: 6px 12px; font-size: 14px; font-weight: 500; color: var(--text-primary); white-space: nowrap; cursor: pointer; }
  .formula-add-item:hover { background: var(--accent-light); color: var(--accent); }
  .formula-actions { position: absolute; top: 12px; right: 16px; display: flex; gap: 4px; align-items: center; }

  /* Prompt Result */
  .prompt-input-area { width: 100%; min-height: 80px; border: none; outline: none; font-size:14px; line-height: 1.8; color: var(--text-primary); font-family: inherit; background: transparent; caret-color: var(--text-primary); font-style: italic; white-space: pre-wrap; word-wrap: break-word; overflow-y: auto; }
  .prompt-input-area:empty::before { content: '\793A\4F8B\FF1A\4E00\4F4D\5E74\8F7B\65C5\884C\8005\FF0C\80CC\7740\80CC\5305\FF0C\72EC\81EA\8D70\5728\6C99\6F20\4E2D\FF0C\5915\9633\897F\4E0B'; color: var(--text-placeholder); font-style: italic; pointer-events: none; }
  .prompt-input-area .tag-span { color: var(--accent); font-style: normal;-webkit-user-select: all; }
  .result-placeholder { color: var(--text-placeholder); font-size:14px; line-height: 1.8; font-style: italic; }
  .result-content { font-size:14px; line-height: 1.8; color: var(--text-primary); white-space: pre-wrap; padding: 8px 0; }
  .result-area { min-height: 60px; padding: 4px 0; position: relative; }
  .loading-overlay { position: absolute; top: 0; left: 0; right: 0; bottom: 0; display: flex; align-items: center; justify-content: center; background: var(--bg-secondary); opacity: 0.85; z-index: 10; border-radius: 8px; transition: opacity 0.2s; }
  .loading-spinner { width: 28px; height: 28px; border: 3px solid var(--border-color); border-top-color: var(--accent); border-radius: 50%; animation: loadingSpin 0.8s linear infinite; }
  @keyframes loadingSpin { to { transform: rotate(360deg); } } .loading-spinner { will-change: transform; }

  /* Buttons */
  .copy-row { display: flex; gap: 8px; flex-wrap: wrap; }
  .warm-tip { font-size: 12px; color: var(--text-tertiary); background: var(--orange-light); border: 2px solid var(--border-light); border-radius: 8px; padding: 10px 14px; margin: 0 16px 16px; line-height: 1.6; }
  .gen-warning { display: none; background: var(--orange-light); border: 2px solid var(--border); border-radius: 10px; padding: 12px 16px; margin: 8px 0; font-size: 13px; line-height: 1.6; color: var(--text-primary); align-items: center; justify-content: space-between; gap: 12px; }
  .gen-warning.active { display: flex; }
  .gen-warning-text { flex: 1; }
  .gen-warning-actions { display: flex; gap: 8px; flex-shrink: 0; }
  .gen-warning-btn { padding: 6px 14px; border-radius: 8px; border: 2px solid var(--border); font-size: 13px; font-weight: 600; cursor: pointer; transition: all 0.15s; background: var(--input-bg); color: var(--text-primary); }
  .gen-warning-btn:hover { border-color: var(--accent); }
  .gen-warning-btn.primary { background: var(--accent); color: var(--bg-primary); border-color: var(--accent); }
  .gen-warning-btn.primary:hover { background: var(--accent-hover); }
  .copy-row-right { display: flex; gap: 6px; justify-content: flex-end; }

  /* Tips */
  .tips-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 24px; }
  .tip-card { background: var(--bg-primary); border: 2px solid var(--border); border-radius:8px; padding: 18px; transition: all 0.2s; display:flex; flex-wrap:wrap; align-items:center; }
  .tip-card:hover { border-color: var(--accent); box-shadow: var(--card-shadow-hover); transform: translateY(-1px); }
  .tip-card-icon { width: 42px; height: 42px; border-radius: 50%; display: flex; align-items: center; justify-content: center; margin-right: 12px; flex-shrink: 0; border: 2px solid var(--border); background: var(--bg-secondary); }
  .tip-card h4 { font-size: 15px; font-weight: 600; }
  .tip-card p { font-size: 14px; color: var(--text-tertiary); line-height: 1.6; flex-basis:100%; margin-top:6px; }
  .tip-label { font-size: 12px; color: var(--text-tertiary); }

  /* Kb Search */
  /* 知识库 */
 .kb-search { display: flex; gap: 8px; align-items: center; margin-bottom: 24px; }
  .search-box { padding: 8px 16px; border-radius: 10px; border: 2px solid var(--border); background: var(--bg-primary); font-size: 14px; width: 420px; outline: none; caret-color: var(--text-primary); transition: all 0.15s; color: var(--text-primary); }
  .search-box::placeholder { color: var(--text-placeholder); font-style: italic; }
  .search-box:focus { border-color: var(--accent); }
  .kb-search-wrap { position: relative; }
  .search-dropdown { display: none; position: absolute; top: 100%; left: 0; width: 420px; max-height: 360px; overflow-y: auto; background: var(--bg-primary); border: 2px solid var(--border); border-radius:8px; box-shadow: var(--dropdown-shadow); z-index: 50; margin-top: 4px; }
  .search-dropdown.open { display: block; }
  .search-dropdown-item { padding: 10px 14px; border-bottom: 2px solid var(--border-light); transition: background 0.1s; cursor: pointer; }
  .search-dropdown-item:last-child { border-bottom: none; }
  .search-dropdown-item:hover { background: var(--bg-secondary); }
  .search-dropdown-item .sd-title { font-size: 14px; font-weight: 600; color: var(--text-primary); margin-bottom: 2px; }
  .search-dropdown-item .sd-snippet { font-size: 14px; color: var(--text-tertiary); line-height: 1.5; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
  .search-dropdown-empty { padding: 24px 14px; text-align: center; color: var(--text-tertiary); font-size: 14px; }
  .search-match-text { background: var(--amber); color: var(--bg-primary); border-radius: 2px; padding: 0 2px; }
  .search-dropdown-item.selected { background: var(--accent-light); }
  .search-label { font-weight: 600; font-size: 15px; color: var(--text-primary); white-space: nowrap; }

  /* Cat Tree */
  /* Tree dropdown */
 .cat-tree-wrap{position:relative;display:inline-block}
  .cat-tree-trigger{display:flex;align-items:center;justify-content:space-between;padding:8px 12px;border:2px solid var(--border);border-radius:10px;background:var(--input-bg);color:var(--text-placeholder);font-size:14px;font-weight:500;min-width:160px;transition:border-color .15s}
  .cat-tree-trigger:hover{border-color:var(--accent)}
  .cat-tree-trigger.disabled{pointer-events:none;background:var(--bg-secondary)}
  .cat-tree-trigger:not(.disabled){color:var(--text-primary)}
  .cat-tree-trigger svg{width:12px;height:12px;stroke:var(--text-tertiary);flex-shrink:0;margin-left:8px}
  .cat-tree-dropdown{display:none;position:absolute;top:100%;left:0;min-width:100%;max-height:320px;overflow-y:auto;background:var(--bg-primary);border:2px solid var(--border);border-radius:10px;box-shadow:var(--dropdown-shadow);z-index:100;padding:4px 0}
  .cat-tree-dropdown.open{display:block}
  .cat-tree-item{padding:0}
  .cat-tree-label{display:flex;align-items:center;gap:6px;padding:8px 12px;border-radius:6px;font-size:14px;font-weight:500;color:var(--text-primary);-webkit-user-select:none}
  .cat-tree-label:hover{background:var(--accent-light);color:var(--accent)}
  .cat-tree-label .arrow{display:inline-flex;align-items:center;color:var(--text-tertiary);transition:transform .15s;width:12px}
  .cat-tree-label .arrow.open{transform:rotate(90deg)}
  .cat-tree-children{display:none;padding-left:16px}
  .cat-tree-children.open{display:block}
  .cat-tree-leaf{padding:6px 12px;font-size:12px;color:var(--accent)}
  .cat-tree-leaf.selected{color:var(--accent);font-weight:600}
  .cat-tree-placeholder { padding: 6px 12px; font-size: 12px; color: var(--text-placeholder);-webkit-user-select: none; }

  /* Kb Cards */
  .kb-card.highlighted { outline: 3px solid #FFC107; outline-offset: 2px; border-radius: 10px; transition: outline 0.2s; background: var(--amber-light); }
  /* KB Group */
 .kb-group { margin-bottom: 24px; }
  .kb-card { background: var(--bg-primary); border: 2px solid var(--border); border-radius: 10px; padding: 14px 16px 16px; transition: all 0.2s; }
  .kb-card-title-row { display: flex; align-items: center; justify-content: flex-start; margin-bottom: 8px; }
  .kb-card-title { font-size: 14px; font-weight: 600; display: inline-flex; align-items: center; gap: 6px; color: var(--text-primary); }
  .kb-card-title svg { stroke-dasharray: none !important; }
  .kb-card-meta { font-size: 12px; color: var(--text-tertiary); white-space: nowrap; margin-left: 12px; }
  .kb-card-tags { display: flex; flex-wrap: wrap; gap: 4px; max-height:54px; overflow:hidden; }
  .kb-tag { font-weight: 500; font-size: 12px; padding: 2px 7px; border-radius: 4px; line-height:1; }
  .kb-card-grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 24px; }
  .kb-card:hover { border-color: var(--accent); box-shadow: var(--card-shadow-hover); transform: translateY(-1px); }
  .kb-card-desc { font-size: 14px; color: var(--text-tertiary); line-height: 1.6; margin: 4px 0 6px; padding: 0 2px; }
  .kb-card-placeholder { pointer-events: none; }

  /* Kb Detail */
  /* KB Detail */
 .kb-detail { background: var(--input-bg); border: 2px solid var(--border); border-radius: 10px; padding: 28px; margin-bottom: 24px; }
  .kb-detail h3 { font-size: 15px; font-weight: 600; margin-bottom: 20px; display: flex; align-items: center; gap: 8px; color: var(--text-primary); }
  .term-table { width: 100%; border-collapse: collapse; margin-bottom: 20px; }
  .term-table td { padding: 12px 14px; border-bottom: 2px solid var(--border-light); font-size: 14px; line-height: 1.6; vertical-align: top; }
  .term-table tr:last-child td { border-bottom: none; }
  .term-table tr:hover td { background: var(--bg-secondary); }
  .term-zh { font-weight: 600; color: var(--text-primary); white-space: nowrap; font-size: 14px; }
  .term-en { color: var(--text-tertiary); font-size: 14px; }
  .term-ref { font-size: 11px; color: var(--text-tertiary); }
  .validity-badge { display: inline-flex; align-items: center; justify-content: center; gap: 4px; padding: 4px 12px; border-radius: 6px; font-size: 13px; font-weight: 600; }
  .validity-strong { background: var(--green-tag); color: #fff; }
  .validity-effective { background: var(--teal); color: #fff; }
  .validity-weak { background: #FFC107; color: #333; }
  .model-series-title { font-size: 14px; font-weight: 600; color: var(--text-primary); margin: 20px 0 10px; padding-left: 10px; border-left: 3px solid var(--accent); display: flex; align-items: center; gap: 6px; }
  .term-zh-click{color:var(--accent)}
  .term-zh-click:hover{text-decoration:underline}
  /* KB 详情四列表格宽度（全部固定宽度，展开后统一） */
.term-table th:nth-child(1) { width: 120px; max-width: 120px; }
  .term-table th:nth-child(2) { width: 220px; max-width: 220px; }
  .term-table th:nth-child(3) { width: 280px; max-width: 280px; white-space: pre-wrap; word-break: break-word; }
  .term-table th { padding: 12px 14px; text-align: left; font-size: 14px; font-weight: 600; color: var(--accent); vertical-align: top; }
  .term-table th:nth-child(4) { width: 80px; max-width: 80px; text-align: center; }
  .term-table td:nth-child(4) { text-align: center; vertical-align: middle; }
  .term-table td:nth-child(3) { white-space: pre-wrap; word-break: break-word; line-height: 1.6; }
  .term-table td:nth-child(2) { white-space: pre-wrap; word-break: break-word; line-height: 1.6; }
  .term-table td:nth-child(1) { white-space: pre-wrap; word-break: break-word; line-height: 1.6; }
  .kb-detail-card { grid-column: 1 / -1; display: none; }
  .kb-detail-card[data-arrow="1"] { --arrow-pos: 12.5%; }
  .kb-detail-card[data-arrow="2"] { --arrow-pos: 37.5%; }
  .kb-detail-card[data-arrow="3"] { --arrow-pos: 62.5%; }
  .kb-detail-card[data-arrow="4"] { --arrow-pos: 87.5%; }
  /* AI Guide table — 4列固定宽度，优势左对齐 */
.ai-guide-detail .term-table th:nth-child(1) { width: 120px; max-width: 120px; }
  .ai-guide-detail .term-table th:nth-child(2) { width: 120px; max-width: 120px; }
  .ai-guide-detail .term-table th:nth-child(3) { width: 230px; max-width: 230px; }
  .ai-guide-detail .term-table th:nth-child(4) { width: 230px; max-width: 230px; }
  .ai-guide-detail .term-table th:first-child, .ai-guide-detail .term-table td:first-child { padding-left: 0; }
  .ai-guide-detail .term-table th:last-child, .ai-guide-detail .term-table td:last-child { padding-right: 0; }
  .ai-guide-detail .term-table th:nth-child(4), .ai-guide-detail .term-table td:nth-child(4) { text-align: left; }
  .ai-guide-detail .term-table th { color: var(--text-primary); }

  /* Ai Guide */
  /* AI模型指南 */
 .ai-guide-card { background: var(--bg-primary); border: 2px solid var(--border); border-radius: 10px; padding: 14px 16px; margin-bottom: 12px; transition: all 0.15s; z-index:1;position:relative;}
  .ai-guide-card:hover { border-color: var(--accent); box-shadow: var(--card-shadow-hover); transform: translateY(-1px); }
  .ai-guide-header { display: flex; align-items: center; justify-content: flex-start; margin-bottom: 10px; }
  .ai-guide-title { font-size: 15px; font-weight: 600; display: flex; align-items: center; gap: 6px; }
  .ai-guide-meta { font-size: 14px; color: var(--text-tertiary); }
  .ai-guide-desc { font-size: 14px; color: var(--text-tertiary); line-height: 1.6; margin-bottom: 12px; }
  .ai-guide-tags { display: flex; flex-wrap: wrap; gap: 6px; }
  .ai-guide-tag { font-weight: 500; font-size: 12px; padding: 2px 7px; border-radius: 4px; line-height:1; }
  .ai-guide-detail { display: none; margin-bottom: 12px; }
  .ai-guide-section-icon { display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 24px; flex-shrink: 0; }
  .ai-guide-section-icon svg { width: 24px; height: 24px; }
  .model-series-icon { width: 18px; height: 18px; }
  .model-series-icon svg { width: 18px; height: 18px; }

  .cobuild-section-icon, .cobuild-header > svg { display: inline-flex; align-items: center; width: 24px; height: 24px; flex-shrink: 0; vertical-align: middle; }

  /* Cobuild */
  /* 词条共建 */
 .cobuild-section { background: var(--bg-primary); border: 2px solid var(--border); border-radius: 10px; padding: 14px 16px; margin-bottom: 24px; transition: all 0.15s; position: relative; z-index: 2; }
  .cobuild-section:hover { border-color: var(--accent); box-shadow: var(--card-shadow-hover); transform: translateY(-1px); }
  .cobuild-header { display: flex; align-items: center; justify-content: flex-start; margin-bottom: 12px; flex-wrap: wrap; gap: 8px; }
  .cobuild-header h3 { font-size: 15px; font-weight: 600; display: flex; align-items: center; gap: 6px; }
  .cobuild-form { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 8px; margin-bottom: 16px; }
  .cobuild-form textarea { padding: 8px 12px; border-radius: 8px; border: 2px solid var(--border); background: var(--input-bg); color: var(--text-primary); font-size: 14px; outline: none; caret-color: var(--text-primary); }
  .cobuild-form textarea:focus { border-color: var(--accent); }
  .cobuild-form textarea { grid-column: 1 / -1; min-height: 60px; resize: vertical; font-family: inherit; overflow-y: auto; }
  .cobuild-form .submit-btn { justify-self: end; }

  /* Input placeholders italic */
.cobuild-form textarea::placeholder { color: var(--text-placeholder); font-style: italic; }
  /* Edit module */
 .cobuild-edit-module{display:none;flex-direction:row;gap:14px;padding:0;grid-column:1/-1;align-items:stretch}
  .cobuild-edit-module.active{display:flex}
  .cobuild-edit-module.disabled .edit-area { background: var(--bg-tertiary); color: var(--text-tertiary); pointer-events: none; }
  .cobuild-edit-module.disabled select { background: var(--bg-tertiary); color: var(--text-tertiary); pointer-events: none; }
  .cobuild-desc-textarea{grid-column:1/-1;min-height:60px;resize:vertical;font-family:inherit;overflow-y:auto}

  /* Edit */
  .edit-field{display:flex;flex-direction:column;gap:4px}
  .edit-field label{font-size:14px;font-weight:600;color:var(--text-secondary);display:flex;align-items:center;gap:6px;letter-spacing:0.02em;text-transform:uppercase}
  .edit-field-name{flex:1}
  .edit-field-desc{flex:1.5}
  .edit-field-ref{flex:1.8}
  .edit-field-val{flex:1}
  .edit-field .edit-area{border:2px solid var(--border);border-radius:10px;padding:12px 14px;background:var(--input-bg);color:var(--text-primary);font-size:14px;line-height:1.6;font-family:var(--font-body);width:100%;min-height:60px;outline:none;caret-color:var(--text-primary);white-space:pre-wrap;word-wrap:break-word;transition:all 0.15s;box-sizing:border-box;flex:1;overflow-y:hidden}
  .edit-field-val .edit-area{cursor:pointer;-webkit-user-select:none;position:relative;overflow-y:visible}
  .edit-field .edit-area:focus{border-color:var(--accent)}
  .edit-ref-text{font-size:14px;color:var(--text-secondary);background:var(--bg-secondary);border:2px solid var(--border);border-radius:10px;padding:12px 14px;line-height:1.6;display:none;white-space:pre-wrap;word-break:break-word;flex:1;box-sizing:border-box;overflow-y:hidden}
  .edit-ref-text.active{display:block}
  .ref-label{font-size:11px;color:var(--text-tertiary);display:none;flex-shrink:0}
  .ref-label.active{display:block}
  .edit-field .edit-area.disabled{pointer-events:none;opacity:0.5}
  .char-count{font-size:11px;color:var(--text-tertiary);text-align:right;margin-top:4px}

  /* Footer */
		
  /* Floating */
  /* 浮动导航 v0.4 */
 .floating-nav { position: fixed; top: 50%; right: 20px; transform: translateY(-50%); z-index: 999; display: flex; flex-direction: column; align-items: flex-end; gap: 8px; transition: opacity 0.25s ease; }
  .fab-btn { width: 44px; height: 44px; border-radius: 50%; border: 2px solid var(--border); background: var(--bg-primary); font-size: 16px; color: var(--text-primary); transition: all 0.2s ease; display: flex; align-items: center; justify-content: center; }
  .fab-btn svg { width: 22px; height: 22px; }
  .fab-btn:hover { background: var(--accent); color: #fff; border-color: var(--accent); }
  .fab-badge { position: absolute; top: -4px; right: -4px; background: #ef4444; color: #fff; font-size: 10px; font-weight: 600; min-width: 16px; height: 16px; border-radius: 8px; display: flex; align-items: center; justify-content: center; padding: 0 4px; box-sizing: border-box; line-height: 1; pointer-events: none; }
  /* notification panel removed - using modal */
  .notification-header { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px 10px; border-bottom: 1px solid var(--border); }
  .notification-header h4 { margin: 0; font-size: 14px; font-weight: 600; color: var(--text-primary); }
  .notification-mark-read { font-size: 12px; color: var(--accent); cursor: pointer; background: none; border: none; padding: 0; font-family: inherit; }
  .notification-mark-read:hover { text-decoration: underline; }
  .notification-list { padding: 4px 0; }
  .notification-item { padding: 10px 16px; border-bottom: 1px solid var(--border); cursor: pointer; transition: background 0.1s; }
  .notification-item:last-child { border-bottom: none; }
  .notification-item:hover { background: var(--bg-secondary); }
  .notification-item.unread { background: var(--accent-light); }
  .notification-item-title { font-size: 14px; font-weight: 600; color: var(--text-primary); margin-bottom: 2px; }
  .notification-item-desc { font-size: 12px; color: var(--text-secondary); line-height: 1.4; }
  .notification-item-time { font-size: 11px; color: var(--text-tertiary); margin-top: 4px; }
  .notification-empty { padding: 32px 16px; text-align: center; font-size: 13px; color: var(--text-tertiary); }
  @media (max-width: 768px) { .floating-nav { left: auto; right: 16px; bottom: 80px; top: auto; transform: none; } }

  /* Misc */
  /* === Migrated inline styles (v0.565) === */
/* d-none 定义在 base.css 中 */
  .section-label-bold { margin-bottom: 0; color: var(--text-primary); font-size: 15px; font-weight: 600; }
  .rule-label { font-size: 12px; color: var(--text-tertiary); }
  .login-hint { display: flex; align-items: center; gap: 8px; color: var(--text-tertiary); font-size: 12px; grid-column: 1 / -1; }

  .status-green { color: var(--green-tag); }
  /* 自定义下拉菜单 */
  .cobuild-select-wrap { position: relative; }
  .cobuild-select-trigger { display: flex; align-items: center; justify-content: space-between; padding: 8px 12px; border: 2px solid var(--border); border-radius: 8px; background: var(--input-bg); color: var(--text-primary); font-size: 14px; font-weight: 500; cursor: pointer; transition: all 0.15s; min-width: 140px; }
  .cobuild-select-trigger:hover { border-color: var(--accent); }
  .cobuild-select-trigger:focus { border-color: var(--accent); outline: none; }
  .cobuild-select-trigger svg { flex-shrink: 0; color: var(--text-tertiary); transition: transform 0.15s; }
  .cobuild-select-trigger.active svg { transform: rotate(180deg); }
  .cobuild-select-dropdown { display: none; position: absolute; top: 100%; left: 0; min-width: 100%; margin-top: 4px; background: var(--bg-primary); border: 2px solid var(--border); border-radius: 10px; box-shadow: var(--dropdown-shadow); z-index: 100; padding: 4px; overflow: hidden; }
  .cobuild-select-option { padding: 8px 12px; border-radius: 6px; font-size: 14px; font-weight: 500; color: var(--text-primary); cursor: pointer; transition: all 0.1s; }
  .cobuild-select-option:hover { background: var(--accent-light); color: var(--accent); }
  .cobuild-select-option.selected { background: var(--accent-light); color: var(--accent); font-weight: 600; }
  .col-120 { width: 120px; }
  .col-80 { width: 80px; }

  /* Other */
  .logo-img { height: 80px; width: auto; flex-shrink: 0; }
  /* 提示词公式条（编辑器卡片外部上方独立行） */
 /* 统一编辑器 */
 .unified-editor { display: flex; flex-direction: column; width: 100%; box-sizing: border-box; }
  /* KB Card v0.4 compact */

  .term-desc { color: var(--text-tertiary); line-height: 1.6; }

  .tag-accent { background: var(--accent-light); color: var(--accent); }
  .tag-muted { background: var(--bg-secondary); color: var(--text-tertiary); }
  .chip-count {
 display: inline-flex; align-items: center; justify-content: center;
 min-width: 16px; height: 16px; border-radius: 50%;
 background: var(--accent); color: #fff;
 font-size: 12px; font-weight: 600; margin-left: 4px; line-height: 1;
 padding: 0 3px;}

  /* Responsive */
  @media (max-width: 768px) { .search-dropdown { width: 200px; }}
  @media (max-width: 480px) { .search-dropdown { width: 100%; }}
  /* Responsive */
 @media (max-width: 1440px) { .page { width: 92%; }}
  @media (max-width: 768px) { .page { width: 100%; padding: 16px; } .tips-row { grid-template-columns: 1fr; } .nav-inner { width: 100%; padding: 0 16px; }  .cobuild-form { grid-template-columns: 1fr; } .workstation-hero h1 { font-size: 28px; } .kb-search .search-box { width: 200px; }}
  @media (max-width: 480px) { .page { padding: 12px; } .editor-mode-switch .mode-btn { padding: 6px 20px; font-size: 12px; } .nav-inner { width: 100%; padding: 0 12px; } .kb-search { width: 100%; } .kb-search .search-box { width: 100%; }}
  @media (min-width: 1800px) { .page { width: 85%; }}
  @media (max-width: 1024px) { .kb-card-grid-4 { grid-template-columns: repeat(2, 1fr); }}
  @media (max-width: 600px) { .kb-card-grid-4 { grid-template-columns: 1fr; }}
  /* Modal / Overlay */
  .modal-overlay { display: none; position: fixed; inset: 0; z-index: 9999; background: rgba(0,0,0,0.6); transition: background 0.25s ease; align-items: center; justify-content: center; padding: 20px; }
  .modal-overlay.active { display: flex; }
  .modal-content { background: var(--bg-primary); border: 2px solid var(--border); border-radius: 12px; max-width: 500px; width: 100%; max-height: 80vh; overflow-y: auto; box-shadow: var(--card-shadow); }
  .modal-content .btn.bp { width: 100%; padding: 10px; font-size: 14px; }
  .modal-body p { line-height: 1.6; }
  .modal-content-wide { max-width: 640px; }
  .modal-header { display: flex; align-items: center; justify-content: space-between; padding: 20px 24px 0; }
  .modal-header h3 { font-size: 16px; font-weight: 600; margin: 0; }
  .modal-close { background: none; border: none; font-size: 24px; cursor: pointer; color: var(--text-tertiary); padding: 0; line-height: 1; }
  .modal-close:hover { color: var(--text-primary); }
  .modal-body { padding: 16px 24px 24px; }
  .legal-body h4 { font-size: 14px; font-weight: 600; margin: 16px 0 6px; color: var(--text-primary); }
  .legal-body p, .legal-body li { font-size: 14px; line-height: 1.7; color: var(--text-primary); margin: 4px 0; }
  .legal-body ul { padding-left: 20px; margin: 4px 0; }
  .legal-body a { color: var(--accent); text-decoration: underline; }
  .legal-update { margin-top: 16px; font-size: 12px; color: var(--text-tertiary); }
  .feedback-label { display: block; font-size: 14px; font-weight: 500; margin-bottom: 6px; color: var(--text-primary); }
  .feedback-type-group { margin-bottom: 14px; }
  .feedback-type-options { display: flex; flex-wrap: wrap; gap: 8px; }
  .feedback-type-option { font-size: 14px; display: flex; align-items: center; gap: 4px; cursor: pointer; color: var(--text-primary); }
  .feedback-type-option input { accent-color: var(--accent); }
  .feedback-field { margin-bottom: 12px; }
  .feedback-textarea { width: 100%; padding: 10px 12px; border: 2px solid var(--border); border-radius: 8px; background: var(--input-bg); color: var(--text-primary); font-size: 14px; resize: vertical; outline: none; font-family: inherit; box-sizing: border-box; overflow-y: auto; }
  .feedback-textarea:focus { border-color: var(--accent); }
  .feedback-input { width: 100%; padding: 10px 12px; border: 2px solid var(--border); border-radius: 8px; background: var(--input-bg); color: var(--text-primary); font-size: 14px; outline: none; box-sizing: border-box; }
  .feedback-input:focus { border-color: var(--accent); }
  .feedback-note { font-size: 12px; color: var(--text-tertiary); margin: 8px 0 4px; text-align: center; }
  /* 表单组 */
  .fg { margin-bottom: 14px; }
  .fg label { display: block; font-size: 13px; font-weight: 600; color: var(--text-secondary); margin-bottom: 6px; }
  .fg input { width: 100%; padding: 10px 12px; border: 2px solid var(--border); border-radius: 8px; background: var(--input-bg); color: var(--text-primary); font-size: 14px; outline: none; box-sizing: border-box; transition: border-color 0.15s; font-family: inherit; }
  .fg input:focus { border-color: var(--accent); }
  .fg input::placeholder { color: var(--text-placeholder); font-style: italic; }
  /* 邮箱自动补全 */
  .email-wrap { position: relative; }
  .email-suggest { position: absolute; top: 100%; left: 0; right: 0; z-index: 100; background: var(--input-bg); border: 2px solid var(--border); border-top: none; border-radius: 0 0 8px 8px; display: none; max-height: 180px; overflow-y: auto; }
  .email-suggest.show { display: block; }
  .email-suggest div { padding: 8px 12px; font-size: 13px; color: var(--text-primary); cursor: pointer; transition: background 0.1s; }
  .email-suggest div:hover { background: var(--accent-light); color: var(--accent); }
  .email-suggest div:last-child { border-radius: 0 0 6px 6px; }
  .email-suggest .match-prefix { font-weight: 600; color: var(--accent); }
  /* Footer merged */

  /* === Migrated inline styles (v0.627) === */
  .fab-btn-notif { position: relative; }
  .feedback-star { color: var(--accent); }
  .btn-feedback-submit { width: 100%; margin-top: 4px; }
  #feedback-success { display: none; text-align: center; padding: 20px 0; color: var(--text-primary); font-size: 14px; }
  .feedback-success-title { margin-top: 12px; font-weight: 600; }
  .feedback-success-desc { font-size: 13px; color: var(--text-tertiary); margin-top: 4px; }
  .feedback-close-btn { margin-top: 12px; }
  /* login-hint — 登录提示 */
.b-h1 { font-family: 'PingFang SC','Microsoft YaHei','SimHei',sans-serif; font-weight: 900; font-size: 48px; }
      .b-p { font-family: 'Inter','PingFang SC','Microsoft YaHei',sans-serif; font-weight: 500; font-size: 16px; }
.cobuild-form .submit-btn:disabled{opacity:0.4;cursor:not-allowed;pointer-events:none}
