:root {
  --research-font-sans: "PingFang SC", "HarmonyOS Sans SC", "Source Han Sans SC", "Noto Sans CJK SC", "Microsoft YaHei", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --research-font-serif: "Songti SC", "STSong", "Source Han Serif SC", "Noto Serif CJK SC", "SimSun", serif;
  --research-font-mono: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
  --research-ink: #17241f;
  --research-muted: #62716a;
  --research-green: #176047;
  --research-primary: #176047;
  --research-green-dark: #0d3d30;
  --research-green-soft: #eaf4ef;
  --research-gold: #c99b43;
  --research-paper: #f6f8f5;
  --research-white: #fff;
  --research-line: #dfe8e3;
  --research-header-height: 72px;
  --research-sidebar-width: 248px;
  --research-shadow: 0 12px 36px rgba(22, 74, 56, 0.07);
}

* { box-sizing: border-box; }
body.research-body { margin: 0; color: var(--research-ink); background: var(--research-paper); font-family: var(--research-font-sans); font-size: 14px; line-height: 1.65; text-rendering: optimizeLegibility; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; }
button:focus-visible, a:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible { outline: 3px solid rgba(201,155,67,.34); outline-offset: 2px; }
.research-header { position: sticky; top: 0; z-index: 50; height: var(--research-header-height); border-bottom: 1px solid rgba(19,73,55,.1); background: rgba(255,255,255,.96); backdrop-filter: blur(14px); }
.research-header-inner { display: grid; grid-template-columns: var(--research-sidebar-width) minmax(0, 1fr) auto; width: 100%; height: 100%; align-items: center; }
.research-brand-area { display: flex; height: 100%; padding: 0 20px; align-items: center; border-right: 1px solid var(--research-line); }
.research-brand { display: flex; align-items: center; gap: 11px; color: var(--research-green-dark); font-size: 15px; font-weight: 700; letter-spacing: .02em; }
.research-brand img { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; }
.research-brand > span { min-width: 0; white-space: nowrap; }
.research-brand small { display: block; margin-top: 1px; color: var(--research-muted); font-size: 9px; font-weight: 600; letter-spacing: 1.35px; }
.research-menu-toggle { display: none; width: 38px; height: 38px; margin-right: 8px; padding: 0; color: var(--research-green-dark); background: transparent; border: 0; border-radius: 9px; cursor: pointer; }
.research-quick-nav { display: flex; min-width: 0; padding: 0 22px; align-items: center; gap: 6px; }
.research-quick-nav a { display: inline-flex; min-height: 38px; padding: 8px 12px; align-items: center; gap: 7px; color: var(--research-muted); font-size: 13px; border-radius: 9px; }
.research-quick-nav a:hover { color: var(--research-green); background: var(--research-green-soft); }
.research-quick-nav a.research-quick-primary { margin-left: 4px; color: var(--research-white); background: var(--research-green); }
.research-quick-nav a.research-quick-primary:hover { background: var(--research-green-dark); }
.research-user-area { display: flex; height: 100%; padding: 0 20px 0 12px; align-items: center; gap: 9px; border-left: 1px solid var(--research-line); }
.research-version { padding: 5px 9px; color: var(--research-green); font-size: 11px; background: var(--research-green-soft); border-radius: 999px; }
.research-user-avatar { display: inline-flex; width: 32px; height: 32px; flex: 0 0 32px; align-items: center; justify-content: center; color: #fff; background: linear-gradient(145deg, var(--research-green), #2b9070); border-radius: 10px; font-size: 13px; font-weight: 700; }
.research-user-name { max-width: 110px; overflow: hidden; color: var(--research-green-dark); font-size: 13px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.research-user-menu { position: relative; }
.research-user-trigger { display: inline-flex; min-height: 42px; padding: 5px 8px 5px 5px; align-items: center; gap: 8px; color: var(--research-ink); background: transparent; border: 1px solid transparent; border-radius: 11px; cursor: pointer; }
.research-user-trigger:hover, .research-user-menu.is-open .research-user-trigger { background: var(--research-green-soft); border-color: #d9e9e1; }
.research-user-chevron { color: var(--research-muted); font-size: 12px; transition: transform .18s ease; }
.research-user-menu.is-open .research-user-chevron { transform: rotate(180deg); }
.research-user-dropdown { position: absolute; top: calc(100% + 9px); right: 0; z-index: 70; width: 280px; padding: 9px; visibility: hidden; background: #fff; border: 1px solid var(--research-line); border-radius: 15px; box-shadow: 0 20px 55px rgba(12,48,39,.18); opacity: 0; transform: translateY(-6px) scale(.98); transform-origin: top right; transition: opacity .16s ease, transform .16s ease, visibility .16s ease; }
.research-user-menu.is-open .research-user-dropdown { visibility: visible; opacity: 1; transform: translateY(0) scale(1); }
.research-user-summary { display: flex; margin-bottom: 6px; padding: 10px; align-items: center; gap: 10px; background: #f5f9f7; border-radius: 11px; }
.research-user-summary > span:last-child { display: grid; min-width: 0; gap: 2px; }
.research-user-summary strong { overflow: hidden; color: var(--research-green-dark); font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.research-user-summary small { color: var(--research-muted); font-size: 10px; }
.research-user-dropdown > a { display: flex; min-height: 50px; padding: 8px 10px; align-items: center; gap: 11px; border-radius: 10px; }
.research-user-dropdown > a:hover, .research-user-dropdown > a:focus { background: var(--research-green-soft); outline: none; }
.research-user-dropdown > a > i { width: 30px; height: 30px; flex: 0 0 30px; color: var(--research-green); background: #edf6f1; border-radius: 9px; line-height: 30px; text-align: center; }
.research-user-dropdown > a > span { display: grid; gap: 2px; }
.research-user-dropdown > a strong { color: var(--research-ink); font-size: 13px; }
.research-user-dropdown > a small { color: var(--research-muted); font-size: 10px; }
.research-user-divider { height: 1px; margin: 6px 5px; background: var(--research-line); }
.research-user-dropdown > a.research-user-logout:hover, .research-user-dropdown > a.research-user-logout:focus { background: #fff3f1; }
.research-user-dropdown > a.research-user-logout > i, .research-user-dropdown > a.research-user-logout strong { color: #a44139; }
.research-user-dropdown > a.research-user-logout > i { background: #fff0ed; }
.research-login-link { display: inline-flex; min-height: 36px; padding: 7px 12px; align-items: center; gap: 7px; color: var(--research-green); background: var(--research-green-soft); border-radius: 9px; font-size: 13px; font-weight: 600; }
.research-shell { display: flex; min-height: calc(100vh - var(--research-header-height)); align-items: stretch; }
.research-sidebar { position: sticky; top: var(--research-header-height); z-index: 35; display: flex; width: var(--research-sidebar-width); height: calc(100vh - var(--research-header-height)); flex: 0 0 var(--research-sidebar-width); flex-direction: column; justify-content: space-between; overflow: auto; color: #d8e9e2; background: linear-gradient(180deg, #123f32 0%, #0c3027 100%); border-right: 1px solid rgba(255,255,255,.07); }
.research-side-nav { padding: 18px 14px 28px; }
.research-side-label { margin: 4px 10px 8px; color: rgba(225,241,235,.48); font-size: 11px; font-weight: 700; letter-spacing: 1.5px; }
.research-side-label-project { margin-top: 25px; }
.research-side-group-label { display: block; margin: 10px 12px 2px; color: rgba(225,241,235,.4); font-size: 9px; font-weight: 700; letter-spacing: 1px; }
.research-side-link { position: relative; display: flex; min-height: 40px; margin: 2px 0; padding: 8px 12px; align-items: center; gap: 12px; color: rgba(234,246,241,.78); border-radius: 10px; font-size: 14px; transition: background .18s ease, color .18s ease; }
.research-side-link i { width: 20px; color: rgba(164,211,193,.82); text-align: center; }
.research-side-link:hover { color: #fff; background: rgba(255,255,255,.08); }
.research-side-link.is-active { color: #fff; background: linear-gradient(90deg, rgba(74,178,137,.34), rgba(62,143,112,.18)); font-weight: 600; }
.research-side-link.is-active::before { position: absolute; left: -14px; width: 3px; height: 24px; content: ""; background: #e0b657; border-radius: 0 3px 3px 0; }
.research-side-link.is-active i { color: #f0c76d; }
.research-project-context { margin: 0 0 10px; padding: 12px; background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.08); border-radius: 11px; }
.research-project-context span { display: block; margin-bottom: 4px; color: rgba(225,241,235,.5); font-size: 10px; }
.research-project-context strong { display: block; overflow: hidden; color: #fff; font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.research-project-empty { display: grid; margin-top: 4px; padding: 16px 14px; gap: 9px; color: rgba(234,246,241,.68); background: rgba(255,255,255,.055); border: 1px dashed rgba(255,255,255,.15); border-radius: 11px; font-size: 12px; line-height: 1.65; }
.research-project-empty i { color: #efc671; font-size: 18px; }
.research-project-empty a { color: #f2ce80; font-weight: 700; }
.research-side-footer { padding: 17px 20px 20px; color: rgba(225,241,235,.56); border-top: 1px solid rgba(255,255,255,.08); }
.research-side-footer div { display: flex; margin-bottom: 5px; align-items: center; gap: 8px; font-size: 11px; }
.research-side-footer i { color: #e2bc67; }
.research-side-footer small { font-size: 10px; }
.research-sidebar-backdrop { display: none; }
.research-workspace { display: flex; min-width: 0; flex: 1; flex-direction: column; }
.research-main { width: 100%; max-width: 1500px; min-height: calc(100vh - 136px); margin: 0 auto; padding: 20px clamp(22px, 1vw, 46px) 32px; }
.research-hero { display: flex; align-items: flex-end; justify-content: space-between; gap: 26px; margin-bottom: 25px; }
.research-hero > div:first-child { min-width: 0; }
.research-eyebrow { margin: 0 0 8px; color: var(--research-green); font-size: 11px; font-weight: 700; letter-spacing: 2.2px; }
.research-hero h1 { margin: 0; color: var(--research-green-dark); font-family: var(--research-font-serif); font-size: clamp(29px, 3vw, 38px); font-weight: 700; letter-spacing: .025em; line-height: 1.28; }
.research-hero p { max-width: 760px; margin: 10px 0 0; color: var(--research-muted); font-size: 14px; line-height: 1.85; }
.research-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.research-btn { display: inline-flex; min-height: 40px; padding: 9px 16px; align-items: center; justify-content: center; gap: 8px; color: var(--research-white); background: var(--research-green); border: 1px solid var(--research-green); border-radius: 10px; cursor: pointer; font-size: 13px; font-weight: 600; letter-spacing: .01em; }
.research-btn:hover { background: var(--research-green-dark); }
.research-btn:disabled { cursor: not-allowed; opacity: .55; }
.research-btn-secondary { color: var(--research-green); background: var(--research-white); border-color: var(--research-line); }
.research-btn-danger { color: #a73c34; background: #fff7f5; border-color: #f0d6d1; }
.research-btn-small { min-height: 32px; padding: 6px 10px; font-size: 12px; }
.research-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 30px; }
.research-stat, .research-card { background: var(--research-white); border: 1px solid var(--research-line); border-radius: 16px; box-shadow: var(--research-shadow); }
.research-stat { padding: 20px; }
.research-stat { position: relative; overflow: hidden; }
.research-stat::after { position: absolute; top: 0; right: 0; width: 54px; height: 4px; content: ""; background: linear-gradient(90deg, var(--research-gold), var(--research-green)); border-radius: 0 0 0 4px; }
.research-stat strong { display: block; color: var(--research-green-dark); font-size: 30px; }
.research-stat span { color: var(--research-muted); font-size: 13px; }
.research-panel { margin-top: 24px; padding: 24px; background: var(--research-white); border: 1px solid var(--research-line); border-radius: 18px; box-shadow: var(--research-shadow); }
.research-panel-head { display: flex; margin-bottom: 18px; align-items: center; justify-content: space-between; gap: 20px; }
.research-panel h2, .research-panel h3 { margin: 0; color: var(--research-green-dark); letter-spacing: .01em; line-height: 1.4; }
.research-panel h2 { font-size: 20px; font-weight: 700; }
.research-panel h3 { font-size: 16px; font-weight: 700; }
.research-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.research-grid > .research-empty:only-child { grid-column: 1 / -1; }
.research-card { display: block; padding: 20px; transition: transform .2s ease, border-color .2s ease; }
.research-card:hover { transform: translateY(-2px); border-color: rgba(23,96,71,.35); }
.research-card h3 { margin: 0 0 8px; font-size: 18px; }
.research-card p { min-height: 44px; margin: 0 0 16px; color: var(--research-muted); font-size: 13px; line-height: 1.7; }
.research-meta, .research-tags { display: flex; flex-wrap: wrap; gap: 8px; color: var(--research-muted); font-size: 12px; }
.research-tag, .research-status { display: inline-flex; padding: 4px 9px; color: var(--research-green); background: var(--research-green-soft); border-radius: 999px; }
.research-status-draft, .research-status-pending, .research-status-todo, .research-status-unverified, .research-status-queued { color: #825b16; background: #fff4db; }
.research-status-active, .research-status-confirmed, .research-status-done, .research-status-ready, .research-status-completed { color: #176047; background: #e5f4ed; }
.research-status-verifying, .research-status-doing, .research-status-running, .research-status-submitted { color: #245f88; background: #e8f3fb; }
.research-status-failed, .research-status-rejected, .research-status-conflicted, .research-status-cancelled { color: #a4433c; background: #fff0ed; }
.research-empty { display: grid; min-height: 150px; padding: 34px 20px; place-items: center; align-content: center; gap: 8px; color: var(--research-muted); text-align: center; background: linear-gradient(145deg, #fbfdfc, #f6faf8); border: 1px dashed #cbdad2; border-radius: 14px; }
.research-empty > i { color: #7eaa98; font-size: 26px; }
.research-empty strong { color: var(--research-green-dark); font-size: 16px; }
.research-empty p { max-width: 560px; margin: 0; line-height: 1.7; }
.research-empty .research-btn { margin-top: 7px; }
.research-filter { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 20px; }
.research-input, .research-select, .research-textarea { width: 100%; padding: 10px 12px; color: var(--research-ink); background: #fff; border: 1px solid #cedbd4; border-radius: 9px; outline: none; font-size: 14px; line-height: 1.55; }
.research-input:focus, .research-select:focus, .research-textarea:focus { border-color: var(--research-green); box-shadow: 0 0 0 3px rgba(23,96,71,.1); }
.research-filter .research-input { width: min(330px, 100%); }
.research-filter .research-select { width: 160px; }
.research-form { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 18px; }
.research-form-panel { max-width: 1120px; margin-right: auto; margin-left: auto; }
.research-field { display: grid; gap: 7px; }
.research-field-full { grid-column: 1 / -1; }
.research-field label { color: var(--research-green-dark); font-size: 13px; font-weight: 600; }
.research-field small { color: var(--research-muted); font-size: 12px; line-height: 1.65; }
.research-input[type="file"] { padding: 6px; color: var(--research-muted); }
.research-input[type="file"]::file-selector-button { margin-right: 12px; padding: 7px 12px; color: var(--research-green-dark); background: var(--research-green-soft); border: 0; border-radius: 7px; cursor: pointer; }
.research-textarea { min-height: 110px; resize: vertical; }
.research-detail-grid { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(280px, .8fr); gap: 22px; }
.research-detail-grid > aside .research-form { grid-template-columns: 1fr; }
.research-detail-grid > aside .research-field-full { grid-column: auto; }
.research-description { color: var(--research-muted); font-size: 14px; line-height: 1.82; white-space: pre-wrap; overflow-wrap: anywhere; }
.research-list { display: grid; gap: 12px; }
.research-list-item { padding: 15px; border: 1px solid var(--research-line); border-radius: 12px; transition: background .18s ease, border-color .18s ease, transform .18s ease; }
a.research-list-item:hover { background: #fbfdfc; border-color: #b9d3c7; transform: translateY(-1px); }
.research-list-item strong { display: block; margin-bottom: 6px; color: #20352c; line-height: 1.55; }
.research-quote { margin: 12px 0; padding: 12px 14px; color: #40574e; background: #f3f8f5; border-left: 3px solid var(--research-gold); border-radius: 0 9px 9px 0; line-height: 1.7; }
.research-check { display: block; padding: 7px 0; color: var(--research-muted); line-height: 1.5; }
.research-alert { margin: 0 0 18px; padding: 13px 16px; color: var(--research-green-dark); background: var(--research-green-soft); border: 1px solid #cfe3d9; border-radius: 11px; }
.research-alert-warning { color: #7a4c12; background: #fff8e8; border-color: #eed6a4; }
.research-subgraph { display: grid; gap: 18px; }
.research-node-list { display: flex; flex-wrap: wrap; gap: 12px; }
.research-node { min-width: 180px; padding: 14px; background: #edf7f2; border: 2px solid #80bca5; border-radius: 14px; }
.research-node.is-local { background: #fff8e9; border-color: #dcb965; }
.research-node strong, .research-node span, .research-node small { display: block; }
.research-node span { margin: 4px 0; color: var(--research-green); font-size: 12px; }
.research-node small { color: var(--research-muted); }
.research-relation-list { display: grid; gap: 8px; }
.research-relation { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; padding: 10px 13px; background: #fafcfb; border: 1px solid var(--research-line); border-radius: 10px; }
.research-relation span { color: var(--research-gold); }
.research-relation small { margin-left: auto; color: var(--research-muted); }
.research-hypothesis { border: 2px solid #e2a83e; background: #fffaf0; }
.research-warning-tag { padding: 4px 8px; color: #8a4f00; background: #ffe6ad; border-radius: 999px; font-weight: 700; }
.research-comments { display: grid; gap: 8px; margin-top: 14px; }
.research-comment { padding: 10px 12px; background: #f8faf9; border-radius: 9px; }
.research-comment strong { display: inline; }
.research-comment span { margin-left: 8px; color: var(--research-muted); font-size: 11px; }
.research-comment p { margin: 6px 0 0; color: var(--research-muted); }
.research-inline-form { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 9px; }
.research-inline-form .research-field { flex: 1 1 160px; }
.research-table { width: 100%; border-collapse: collapse; }
.research-table th, .research-table td { padding: 12px; text-align: left; border-bottom: 1px solid var(--research-line); line-height: 1.65; }
.research-table th { color: var(--research-muted); font-size: 12px; }
.research-table thead th { position: sticky; top: 0; z-index: 1; background: #f8fbf9; }
.research-capability-grid { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 14px; margin: -4px 0 2px; }
.research-capability-card { display: grid; min-height: 178px; padding: 20px; align-content: start; gap: 9px; background: #fff; border: 1px solid var(--research-line); border-radius: 16px; box-shadow: var(--research-shadow); }
.research-capability-card > i { display: grid; width: 38px; height: 38px; place-items: center; color: var(--research-green); background: var(--research-green-soft); border-radius: 11px; font-size: 17px; }
.research-capability-card h2 { margin: 2px 0 0; color: var(--research-green-dark); font-size: 17px; }
.research-capability-card p { margin: 0; color: var(--research-muted); font-size: 12px; line-height: 1.6; }
.research-capability-links { display: flex; flex-wrap: wrap; gap: 7px; margin-top: auto; padding-top: 4px; }
.research-capability-links a { padding: 6px 9px; color: var(--research-green); background: #f1f7f4; border-radius: 8px; font-size: 12px; font-weight: 600; }
.research-capability-links a:hover { color: #fff; background: var(--research-green); }
.research-search-scopes { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.research-search-scope { position: relative; display: inline-flex; min-height: 38px; padding: 8px 12px; align-items: center; gap: 7px; color: var(--research-green-dark); background: #f6faf8; border: 1px solid #d7e5de; border-radius: 10px; cursor: pointer; }
.research-search-scope:has(input:checked) { color: var(--research-green); background: var(--research-green-soft); border-color: #9fc9b7; font-weight: 600; }
.research-search-scope input { width: 15px; height: 15px; margin: 0; accent-color: var(--research-green); }
.research-ai-layout { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 18px; align-items: start; }
.research-ai-sessions { position: sticky; top: 92px; max-height: calc(100vh - 120px); overflow: auto; }
.research-ai-sessions h3 { margin: 20px 0 10px; }
.research-ai-sessions .research-list-item.is-active { border-color: var(--research-primary); background: rgba(10, 128, 112, .07); }
.research-ai-chat { display: flex; min-height: min(650px, calc(100vh - 280px)); padding: 0; flex-direction: column; overflow: hidden; }
.research-ai-messages { min-height: 300px; overflow: auto; padding: 24px; flex: 1 1 auto; background: linear-gradient(180deg, rgba(240,250,247,.7), #fff 35%); }
.research-ai-welcome { text-align: center; max-width: 620px; margin: 80px auto; color: var(--research-muted); }
.research-ai-welcome > i { font-size: 34px; color: var(--research-primary); }
.research-ai-welcome .research-tags { justify-content: center; }
.research-ai-welcome button, .research-ai-followups button { border: 1px solid var(--research-line); background: #fff; color: var(--research-primary); border-radius: 999px; padding: 8px 12px; cursor: pointer; }
.research-ai-message { display: grid; grid-template-columns: 36px minmax(0, 1fr); gap: 12px; margin-bottom: 22px; }
.research-ai-role { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; color: #fff; background: var(--research-primary); font-weight: 700; }
.research-ai-message.is-user .research-ai-role { background: #c28a2c; }
.research-ai-message.is-assistant { width: min(94%, 980px); margin-right: auto; }
.research-ai-message.is-user { width: min(78%, 760px); margin-right: 0; margin-left: auto; grid-template-columns: minmax(0, 1fr) 36px; }
.research-ai-message.is-user .research-ai-role { grid-column: 2; grid-row: 1; }
.research-ai-message.is-user > div:last-child { min-width: 0; grid-column: 1; grid-row: 1; }
.research-ai-content { min-width: 0; padding: 16px 18px; color: #263b32; background: #fff; border: 1px solid var(--research-line); border-radius: 4px 16px 16px 16px; font-size: 15px; line-height: 1.82; box-shadow: 0 8px 24px rgba(18,63,50,.035); overflow-wrap: anywhere; }
.research-ai-message.is-user .research-ai-content { color: #234638; background: linear-gradient(145deg, #edf7f2, #f6fbf8); border-color: #cfe3d9; border-radius: 16px 4px 16px 16px; box-shadow: 0 8px 22px rgba(23,96,71,.05); }
.research-ai-message.is-user .research-ai-content { white-space: pre-wrap; }
.research-ai-content.is-error { color: #a33; background: #fff5f5; }
.research-ai-citations { margin-top: 12px; padding: 13px 15px; color: #52675e; background: #f6faf9; border: 1px solid #dfebe5; border-left: 3px solid var(--research-primary); border-radius: 0 10px 10px 0; font-size: 12px; line-height: 1.75; }
.research-ai-citations > strong { display: block; margin-bottom: 5px; color: var(--research-green-dark); font-size: 13px; }
.research-ai-citations > div + div { margin-top: 3px; }
.research-ai-citations span { color: var(--research-primary); font-weight: 700; }
.research-ai-followups { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.research-ai-composer { position: sticky; bottom: 0; z-index: 3; padding: 14px 20px 18px; border-top: 1px solid var(--research-line); background: #fff; box-shadow: 0 -10px 30px rgba(13,61,48,.035); }
.research-ai-composer .research-textarea { width: 100%; margin: 10px 0; }
.research-ai-mode { display: flex; align-items: center; gap: 10px; color: var(--research-muted); font-size: 12px; }
.research-ai-mode .research-select { width: auto; padding: 7px 30px 7px 10px; }
.research-ai-compose-actions { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.research-ai-compose-actions small { color: var(--research-muted); line-height: 1.5; }
.research-ai-status { min-height: 18px; color: var(--research-green); font-size: 12px; }

/* 安全 Markdown / 科研长文本排版 */
.research-markdown { color: #293d35; font-size: 15px; line-height: 1.86; word-break: normal; overflow-wrap: anywhere; }
.research-markdown > :first-child { margin-top: 0 !important; }
.research-markdown > :last-child { margin-bottom: 0 !important; }
.research-markdown p { margin: .72em 0; }
.research-markdown h1, .research-markdown h2, .research-markdown h3, .research-markdown h4 { margin: 1.35em 0 .62em; color: var(--research-green-dark); font-family: var(--research-font-sans); font-weight: 700; letter-spacing: .01em; line-height: 1.45; }
.research-markdown h1 { padding-bottom: .35em; border-bottom: 1px solid var(--research-line); font-size: 1.42em; }
.research-markdown h2 { padding-bottom: .3em; border-bottom: 1px solid #e8efeb; font-size: 1.25em; }
.research-markdown h3 { font-size: 1.1em; }
.research-markdown h4 { font-size: 1em; }
.research-markdown strong { color: #173f31; font-weight: 700; }
.research-markdown em { color: #53675f; }
.research-markdown ul, .research-markdown ol { margin: .72em 0; padding-left: 1.7em; }
.research-markdown li { padding-left: .16em; }
.research-markdown li + li { margin-top: .35em; }
.research-markdown li::marker { color: var(--research-green); font-weight: 700; }
.research-markdown blockquote { margin: 1em 0; padding: .72em 1em; color: #4c6259; background: #f4f8f6; border-left: 3px solid var(--research-gold); border-radius: 0 9px 9px 0; }
.research-markdown blockquote p { margin: .25em 0; }
.research-markdown code { padding: .16em .38em; color: #8f3f32; background: #f3f0e9; border: 1px solid #e8e0d2; border-radius: 5px; font-family: var(--research-font-mono); font-size: .88em; }
.research-markdown pre { margin: 1em 0; padding: 15px 17px; overflow: auto; color: #e8f4ef; background: #12352b; border: 1px solid #0d2d25; border-radius: 11px; font-family: var(--research-font-mono); font-size: 12.5px; line-height: 1.7; tab-size: 2; }
.research-markdown pre code { padding: 0; color: inherit; background: transparent; border: 0; border-radius: 0; font-size: inherit; }
.research-markdown a { color: #176b50; border-bottom: 1px solid rgba(23,107,80,.28); font-weight: 600; }
.research-markdown a:hover { color: #0d3d30; border-bottom-color: currentColor; }
.research-markdown hr { height: 1px; margin: 1.4em 0; background: var(--research-line); border: 0; }
.research-markdown mark { padding: .05em .25em; color: #62420d; background: #fff0bd; border-radius: 3px; }
.research-markdown del { color: #829088; }
.research-markdown-citation { display: inline-flex; margin: 0 .08em; padding: .06em .38em; color: #176047; background: #e8f4ee; border-radius: 5px; font-size: .86em; font-weight: 700; line-height: 1.45; vertical-align: .08em; }
.research-markdown-table { max-width: 100%; margin: 1em 0; overflow-x: auto; border: 1px solid var(--research-line); border-radius: 10px; }
.research-markdown table { width: 100%; min-width: 480px; border-collapse: collapse; background: #fff; font-size: 13px; line-height: 1.6; }
.research-markdown th, .research-markdown td { padding: 10px 12px; text-align: left; border-right: 1px solid var(--research-line); border-bottom: 1px solid var(--research-line); vertical-align: top; }
.research-markdown th:last-child, .research-markdown td:last-child { border-right: 0; }
.research-markdown tr:last-child td { border-bottom: 0; }
.research-markdown th { color: var(--research-green-dark); background: #f3f8f5; font-weight: 700; }
.research-markdown tbody tr:nth-child(even) { background: #fbfdfc; }
.research-longform { max-width: 860px; }
.research-longform.research-markdown { font-size: 14px; }
.research-meta, .research-stat, .research-status, .research-tag, .research-version, .research-table, time { font-variant-numeric: tabular-nums; }
@media (max-width: 1100px) { .research-capability-grid { grid-template-columns: repeat(2, minmax(0,1fr)); } }
@media (max-width: 900px) { .research-ai-layout { grid-template-columns: 1fr; } .research-ai-chat { min-height: 600px; order: 1; } .research-ai-sessions { position: static; max-height: none; order: 2; } .research-ai-sessions .research-list { display: flex; overflow: auto; padding-bottom: 4px; grid-auto-flow: column; grid-auto-columns: minmax(190px, 70%); } .research-ai-messages { min-height: 320px; } }
.research-footer { display: flex; min-height: 64px; padding: 18px clamp(22px, 3vw, 46px); align-items: center; justify-content: space-between; gap: 16px; color: var(--research-muted); background: rgba(255,255,255,.55); border-top: 1px solid var(--research-line); font-size: 12px; }
.pagination { margin-top: 20px; }

@media (max-width: 1180px) {
  :root { --research-sidebar-width: 220px; }
  .research-brand-area { padding: 0 15px; }
  .research-brand img { width: 36px; height: 36px; }
  .research-brand small { display: none; }
  .research-quick-nav { padding: 0 13px; }
  .research-quick-nav a { padding: 8px 9px; }
  .research-user-area { padding-right: 13px; }
  .research-user-name { max-width: 80px; }
}
@media (max-width: 900px) {
  .research-stats { grid-template-columns: repeat(2, 1fr); }
  .research-grid { grid-template-columns: repeat(2, 1fr); }
  .research-detail-grid { grid-template-columns: 1fr; }
  .research-quick-nav a span { display: none; }
  .research-quick-nav a { width: 38px; justify-content: center; }
  .research-quick-nav a.research-quick-primary { margin-left: 0; }
  .research-user-name { display: none; }
}
@media (max-width: 760px) {
  :root { --research-header-height: 64px; }
  body.research-menu-open { overflow: hidden; }
  .research-header-inner { display: flex; justify-content: space-between; }
  .research-brand-area { min-width: 0; flex: 1; border-right: 0; }
  .research-menu-toggle { display: inline-flex; flex: 0 0 38px; align-items: center; justify-content: center; }
  .research-brand img { width: 34px; height: 34px; }
  .research-brand > span { overflow: hidden; font-size: 14px; text-overflow: ellipsis; }
  .research-quick-nav { display: none; }
  .research-user-area { height: 100%; padding: 0 13px; border-left: 0; }
  .research-user-avatar { width: 30px; height: 30px; flex-basis: 30px; }
  .research-user-trigger { padding-right: 5px; }
  .research-user-dropdown { position: fixed; top: calc(var(--research-header-height) - 1px); right: 10px; width: min(300px, calc(100vw - 20px)); }
  .research-version { display: none; }
  .research-sidebar { position: fixed; top: var(--research-header-height); bottom: 0; left: 0; z-index: 45; width: min(82vw, 280px); height: auto; transform: translateX(-102%); transition: transform .22s ease; }
  .research-menu-open .research-sidebar { transform: translateX(0); }
  .research-sidebar-backdrop { position: fixed; inset: var(--research-header-height) 0 0; z-index: 40; display: block; padding: 0; visibility: hidden; background: rgba(8,29,23,.42); border: 0; opacity: 0; transition: opacity .2s ease, visibility .2s ease; }
  .research-menu-open .research-sidebar-backdrop { visibility: visible; opacity: 1; }
  .research-main { padding: 25px 16px 42px; }
  .research-hero { margin-bottom: 18px; align-items: flex-start; flex-direction: column; gap: 16px; }
  .research-hero h1 { font-size: clamp(27px, 8vw, 34px); line-height: 1.25; }
  .research-hero p { margin-top: 7px; line-height: 1.65; }
  .research-actions { width: 100%; }
  .research-stats { grid-template-columns: repeat(2, minmax(0,1fr)); gap: 10px; }
  .research-grid, .research-form { grid-template-columns: 1fr; }
  .research-stat { padding: 16px; }
  .research-capability-grid { grid-template-columns: 1fr; }
  .research-capability-card { min-height: auto; }
  .research-field-full { grid-column: auto; }
  .research-panel { padding: 18px; }
  .research-panel-head { align-items: flex-start; flex-direction: column; gap: 8px; }
  .research-ai-chat { min-height: 540px; }
  .research-ai-messages { min-height: 290px; padding: 18px 14px; }
  .research-ai-welcome { margin: 45px auto; }
  .research-ai-message { grid-template-columns: 30px minmax(0,1fr); gap: 9px; }
  .research-ai-message.is-assistant { width: 100%; }
  .research-ai-message.is-user { width: min(92%, 620px); grid-template-columns: minmax(0,1fr) 30px; }
  .research-ai-role { width: 30px; height: 30px; border-radius: 9px; font-size: 12px; }
  .research-ai-content { padding: 14px 15px; font-size: 14px; line-height: 1.8; }
  .research-markdown table { min-width: 420px; }
  .research-ai-composer { padding: 12px 14px 15px; }
  .research-ai-mode { flex-wrap: wrap; }
  .research-ai-mode > span { width: 100%; }
  .research-ai-compose-actions small { display: none; }
  .research-filter .research-input, .research-filter .research-select, .research-filter .research-btn, .research-filter > a { width: 100%; }
  .research-footer { padding: 18px 16px; align-items: flex-start; flex-direction: column; gap: 4px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}
