/* ═══════════════════════════════════
   顶部状态栏 topbar
═══════════════════════════════════ */
topbar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px 0;
  background: linear-gradient(135deg, rgba(15,20,35,0.92) 0%, rgba(22,30,50,0.88) 100%);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(100,130,180,0.2);
  border-radius: 10px;
  padding: 8px 14px;
  margin-bottom: 14px;
  font-family: 'Courier New', monospace;
  font-size: 0.78em;
  letter-spacing: 0.04em;
  color: #8faac8;
  box-shadow: 0 2px 16px rgba(0,10,30,0.4), inset 0 1px 0 rgba(255,255,255,0.04);
}
topbar .tb-item {
  padding: 0 10px;
  color: #a8c0dc;
  transition: color 0.2s ease;
}
topbar .tb-item:hover {
  color: #cfe0f5;
}
topbar .tb-divider {
  color: rgba(100,130,180,0.3);
  font-size: 0.9em;
}
/* ═══════════════════════════════════
   思维链隐藏 think
═══════════════════════════════════ */
think {
  display: none;
}
/* ═══════════════════════════════════
   正文区域 text
═══════════════════════════════════ */
text {
  display: block;
  background: linear-gradient(160deg, rgba(18,23,38,0.96) 0%, rgba(14,18,30,0.98) 100%);
  border: 1px solid rgba(90,120,170,0.18);
  border-left: 3px solid rgba(100,140,200,0.35);
  border-radius: 0 10px 10px 0;
  padding: 20px 22px 20px 20px;
  margin-bottom: 14px;
  font-family: 'Georgia', 'Noto Serif SC', serif;
  font-size: 0.95em;
  line-height: 2.0;
  color: #d4dce8;
  letter-spacing: 0.02em;
  box-shadow: 0 4px 24px rgba(0,8,25,0.35), inset 0 0 40px rgba(10,20,40,0.2);
  position: relative;
  overflow: hidden;
}
text::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(120,160,220,0.3), transparent);
}
text p {
  margin: 0 0 1.1em 0;
  text-indent: 2em;
}
text p:last-child {
  margin-bottom: 0;
}
/* ═══════════════════════════════════
   状态面板外层 details/summary
═══════════════════════════════════ */
details {
  background: rgba(12,17,30,0.9);
  border: 1px solid rgba(80,110,160,0.2);
  border-radius: 10px;
  margin-bottom: 10px;
  overflow: hidden;
  transition: box-shadow 0.3s ease;
}
details[open] {
  box-shadow: 0 4px 20px rgba(0,8,25,0.4);
}
details > summary {
  list-style: none;
  cursor: pointer;
  padding: 10px 16px;
  font-family: 'Courier New', monospace;
  font-size: 0.82em;
  letter-spacing: 0.08em;
  color: #7a9bbf;
  background: linear-gradient(90deg, rgba(20,30,55,0.95) 0%, rgba(15,22,40,0.95) 100%);
  border-bottom: 1px solid transparent;
  transition: all 0.25s ease;
  display: flex;
  align-items: center;
  gap: 8px;
  user-select: none;
}
details > summary::before {
  content: '▶';
  font-size: 0.7em;
  color: rgba(100,140,200,0.5);
  transition: transform 0.25s ease, color 0.25s ease;
  display: inline-block;
}
details[open] > summary::before {
  transform: rotate(90deg);
  color: rgba(120,170,230,0.8);
}
details[open] > summary {
  color: #a0c0e0;
  border-bottom: 1px solid rgba(80,110,160,0.2);
  background: linear-gradient(90deg, rgba(25,38,65,0.95) 0%, rgba(18,28,48,0.95) 100%);
}
details > summary::-webkit-details-marker {
  display: none;
}
details > summary:hover {
  color: #b8d4f0;
  background: linear-gradient(90deg, rgba(28,42,70,0.95) 0%, rgba(20,32,55,0.95) 100%);
}
/* ═══════════════════════════════════
   statusbar 内部整体
═══════════════════════════════════ */
statusbar {
  display: block;
  padding: 12px 14px 8px;
}
/* ═══════════════════════════════════
   信息块 sb-section
═══════════════════════════════════ */
statusbar .sb-section {
  margin-bottom: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(60,90,140,0.15);
}
statusbar .sb-section:last-child {
  border-bottom: none;
  margin-bottom: 0;
}
/* 标题 sb-title */
statusbar .sb-title {
  font-family: 'Courier New', monospace;
  font-size: 0.72em;
  letter-spacing: 0.12em;
  color: #5a7fa8;
  text-transform: uppercase;
  margin-bottom: 8px;
  padding-bottom: 4px;
  border-bottom: 1px solid rgba(60,100,160,0.12);
  position: relative;
}
statusbar .sb-title::after {
  content: '';
  position: absolute;
  bottom: -1px; left: 0;
  width: 30px;
  height: 1px;
  background: rgba(100,160,230,0.4);
}
/* 行 sb-row */
statusbar .sb-row {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding: 3px 4px;
  border-radius: 4px;
  transition: background 0.2s ease;
  font-size: 0.83em;
}
statusbar .sb-row:hover {
  background: rgba(60,100,160,0.08);
}
/* 标签 sb-label */
statusbar .sb-label {
  flex-shrink: 0;
  width: 72px;
  color: #4e6e90;
  font-family: 'Courier New', monospace;
  font-size: 0.9em;
  letter-spacing: 0.02em;
}
/* 值 sb-val */
statusbar .sb-val {
  color: #b8cce0;
  flex: 1;
  line-height: 1.5;
  word-break: break-all;
}
/* 记忆条目 memory-item */
statusbar .memory-item {
  font-size: 0.8em;
  color: #7090b0;
  padding: 4px 6px;
  margin-bottom: 4px;
  border-left: 2px solid rgba(80,120,180,0.2);
  line-height: 1.6;
  font-family: 'Courier New', monospace;
  transition: border-color 0.2s ease, color 0.2s ease;
}
statusbar .memory-item:hover {
  border-left-color: rgba(100,160,230,0.5);
  color: #90b0d0;
}
/* ═══════════════════════════════════
   顾辞川身体状态观测 guc-obs（玫瑰灰调）
═══════════════════════════════════ */
statusbar .guc-obs {
  position: relative;
  background: rgba(22,10,16,0.65);
  border: 1px solid rgba(140,70,90,0.2);
  border-radius: 6px;
  padding: 10px 12px;
  margin-top: 4px;
}
statusbar .guc-obs::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 6px;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 3px,
    rgba(120,50,70,0.03) 3px,
    rgba(120,50,70,0.03) 4px
  );
  pointer-events: none;
}
statusbar .guc-obs .sb-title {
  color: #7a4a58;
  letter-spacing: 0.15em;
}
statusbar .guc-obs .sb-title::after {
  background: rgba(180,90,120,0.35);
}
statusbar .guc-obs .sb-row:hover {
  background: rgba(120,50,70,0.08);
}
statusbar .guc-obs .sb-label {
  color: #6a3a4a;
}
statusbar .guc-obs .sb-val {
  color: #c8a0b0;
}
/* 顾辞川遮蔽文字 guc-obs-blocked */
statusbar .guc-obs-blocked {
  font-family: 'Courier New', monospace;
  color: #4a2030;
  letter-spacing: 0.06em;
  animation: guc-signal-lost 3.0s ease-in-out infinite;
}
@keyframes guc-signal-lost {
  0%, 100% { opacity: 0.45; }
  40% { opacity: 0.18; }
  70% { opacity: 0.35; }
}
/* 顾辞川观测条件 guc-obs-cond */
statusbar .guc-obs-cond {
  font-family: 'Courier New', monospace;
  font-size: 0.88em;
  color: #c090a8;
}
/* ═══════════════════════════════════
   嵌套 details（记忆档案/顾辞川身体状态）
═══════════════════════════════════ */
statusbar details {
  background: rgba(10,14,24,0.7);
  border: 1px solid rgba(60,90,140,0.15);
  border-radius: 6px;
  margin: 8px 0 4px;
}
statusbar details > summary {
  font-size: 0.78em;
  padding: 7px 12px;
  color: #5a7a9a;
  background: rgba(15,22,38,0.9);
  letter-spacing: 0.06em;
}
statusbar details[open] > summary {
  color: #88aac8;
  background: rgba(18,28,48,0.9);
}
statusbar details > summary:hover {
  color: #9abbd8;
  background: rgba(20,32,55,0.9);
}
/* 顾辞川身体状态折叠块 summary 玫瑰灰调覆盖 */
statusbar details:has(.guc-obs) > summary {
  color: #7a5060;
  background: rgba(28,14,20,0.9);
}
statusbar details:has(.guc-obs)[open] > summary {
  color: #b07888;
  background: rgba(32,16,24,0.9);
  border-bottom-color: rgba(120,60,80,0.2);
}
statusbar details:has(.guc-obs) > summary:hover {
  color: #c090a0;
  background: rgba(36,18,26,0.9);
}
statusbar details:has(.guc-obs)[open] > summary::before {
  color: rgba(180,100,130,0.8);
}
/* ═══════════════════════════════════
   推荐行动 actionbar（琥珀金调）
═══════════════════════════════════ */
actionbar {
  display: block;
  background: linear-gradient(135deg, rgba(20,16,10,0.95) 0%, rgba(16,12,8,0.98) 100%);
  border: 1px solid rgba(160,120,50,0.2);
  border-top: 2px solid rgba(160,120,50,0.25);
  border-radius: 10px;
  padding: 12px 16px 14px;
  margin-top: 10px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 2px 16px rgba(0,0,0,0.4), inset 0 0 30px rgba(30,20,5,0.3);
}
actionbar::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(200,160,60,0.3), transparent);
}
actionbar .action-title {
  font-family: 'Courier New', monospace;
  font-size: 0.72em;
  letter-spacing: 0.14em;
  color: #806040;
  margin-bottom: 10px;
  padding-bottom: 6px;
  border-bottom: 1px solid rgba(140,100,40,0.15);
  position: relative;
}
actionbar .action-title::after {
  content: '';
  position: absolute;
  bottom: -1px; left: 0;
  width: 24px;
  height: 1px;
  background: rgba(200,160,60,0.4);
}
actionbar .action-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 6px 8px;
  border-radius: 6px;
  margin-bottom: 4px;
  transition: background 0.2s ease;
  cursor: default;
}
actionbar .action-item:last-child {
  margin-bottom: 0;
}
actionbar .action-item:hover {
  background: rgba(140,100,30,0.08);
}
actionbar .action-icon {
  flex-shrink: 0;
  font-family: 'Courier New', monospace;
  font-size: 0.75em;
  letter-spacing: 0.06em;
  padding: 2px 7px;
  border-radius: 3px;
  margin-top: 1px;
  font-weight: bold;
}
actionbar .tag-safe {
  color: #5ab890;
  background: rgba(50,140,100,0.12);
  border: 1px solid rgba(50,140,100,0.2);
}
actionbar .tag-risk {
  color: #c8a040;
  background: rgba(160,120,30,0.12);
  border: 1px solid rgba(160,120,30,0.2);
}
actionbar .tag-danger {
  color: #c06070;
  background: rgba(160,60,70,0.12);
  border: 1px solid rgba(160,60,70,0.2);
}
actionbar .action-desc {
  flex: 1;
  font-size: 0.85em;
  color: #b0a090;
  line-height: 1.6;
  font-family: 'Georgia', 'Noto Serif SC', serif;
  letter-spacing: 0.01em;
  transition: color 0.2s ease;
}
actionbar .action-item:hover .action-desc {
  color: #ccc0b0;
}
/* ═══════════════════════════════════
   移动端适配
═══════════════════════════════════ */
@media (max-width: 600px) {
  topbar {
    padding: 6px 10px;
    font-size: 0.72em;
    gap: 2px 0;
  }
  topbar .tb-item {
    padding: 0 6px;
  }
  text {
    padding: 16px 14px 16px 13px;
    font-size: 0.9em;
    line-height: 1.9;
  }
  statusbar .sb-label {
    width: 62px;
    font-size: 0.85em;
  }
  statusbar .sb-row {
    font-size: 0.8em;
  }
  actionbar {
    padding: 10px 12px 12px;
  }
  actionbar .action-desc {
    font-size: 0.82em;
  }
}