/* =========================================
   修仙RPG交互面板专属美化 CSS
   主题: 霜寒剑尊与星回廊 (兼容深浅色模式)
========================================= */

/* ----------------------------------
   1. 外层面板全局样式 (大模块容器)
---------------------------------- */
.markdown-body details {
  background-color: rgba(125, 148, 179, 0.04) !important;
  border: 1px solid rgba(100, 120, 150, 0.25) !important;
  border-radius: 8px !important;
  margin-bottom: 14px !important;
  overflow: hidden !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.03) !important;
  transition: all 0.3s ease-in-out !important;
}

/* 悬浮时微发光效果 */
.markdown-body details:hover {
  border-color: rgba(56, 189, 248, 0.4) !important;
  box-shadow: 0 4px 12px rgba(56, 189, 248, 0.08) !important;
}

/* ----------------------------------
   2. 主标题栏 (大模块头部)
---------------------------------- */
.markdown-body summary {
  padding: 12px 16px !important;
  background: linear-gradient(90deg, rgba(56, 189, 248, 0.12) 0%, rgba(56, 189, 248, 0.02) 100%) !important;
  font-weight: 600 !important;
  font-size: 1.05em !important;
  cursor: pointer !important;
  outline: none !important;
  border-bottom: 1px solid transparent !important;
  user-select: none !important;
  display: flex !important;
  align-items: center !important;
}

/* 展开状态的标题栏底边框 */
.markdown-body details[open] > summary {
  border-bottom: 1px solid rgba(100, 120, 150, 0.2) !important;
  background: linear-gradient(90deg, rgba(56, 189, 248, 0.18) 0%, rgba(56, 189, 248, 0.04) 100%) !important;
}

/* 修复内部段落间距 */
.markdown-body details > p, 
.markdown-body details > div {
  padding: 12px 16px !important;
  margin: 0 !important;
  line-height: 1.7 !important;
}

/* ----------------------------------
   3. 内层面板样式 (子分区/私密花园等)
---------------------------------- */
.markdown-body details details {
  margin: 8px 16px 14px 16px !important;
  border: 1px dashed rgba(100, 120, 150, 0.35) !important;
  background-color: rgba(0, 0, 0, 0.02) !important;
  border-radius: 6px !important;
  box-shadow: none !important;
}

/* 子面板标题栏 */
.markdown-body details details summary {
  background: rgba(100, 120, 150, 0.06) !important;
  padding: 8px 14px !important;
  font-size: 0.95em !important;
  font-weight: 500 !important;
}

.markdown-body details details[open] > summary {
  border-bottom: 1px dashed rgba(100, 120, 150, 0.3) !important;
}

/* ----------------------------------
   4. 角色与系统特殊文本标识
---------------------------------- */
/* 玩家名 - 璨金/暖色 */
.markdown-body .pc-name {
  color: #d97706 !important;
  font-weight: bold !important;
  text-shadow: 0 0 2px rgba(217, 119, 6, 0.2) !important;
}

/* 冷清霄名 - 冰蓝/清冷色 */
.markdown-body .lqx-name {
  color: #0284c7 !important;
  font-weight: bold !important;
  letter-spacing: 1px !important;
  text-shadow: 0 0 4px rgba(14, 165, 233, 0.3) !important;
}

/* 冷清霄心声 - 羞涩紫/高亮 */
.markdown-body .lqx-mind {
  color: #8b5cf6 !important;
  font-style: italic !important;
  background: rgba(139, 92, 246, 0.08) !important;
  padding: 2px 6px !important;
  border-radius: 4px !important;
}

/* NPC心声 - 翡翠绿/幽静 */
.markdown-body .npc-talk {
  color: #059669 !important;
  font-style: italic !important;
}

/* 系统播报 - 警戒红/全息感 */
.markdown-body .sys-voice {
  color: #ea580c !important;
  font-weight: bold !important;
  font-family: monospace, sans-serif !important;
  background: rgba(234, 88, 12, 0.1) !important;
  padding: 3px 8px !important;
  border-radius: 4px !important;
  border-left: 4px solid #ea580c !important;
  box-shadow: 0 0 5px rgba(234, 88, 12, 0.1) !important;
}

/* ----------------------------------
   5. 状态/情感进度条 (方块拼凑型)
---------------------------------- */
.markdown-body .bar {
  display: inline-block !important;
  letter-spacing: -2px !important; /* 让方块紧凑 */
  margin-left: 6px !important;
  vertical-align: 1px !important;
}

/* 已填充进度 - 荧光青 */
.markdown-body .bf {
  color: #0ea5e9 !important;
  text-shadow: 0 0 5px rgba(14, 165, 233, 0.6) !important;
}

/* 未填充进度 - 暗淡灰 */
.markdown-body .be {
  color: #94a3b8 !important;
  opacity: 0.4 !important;
}

/* ----------------------------------
   6. 星记忆回廊 (表格区域)
---------------------------------- */
.markdown-body details table {
  width: calc(100% - 32px) !important;
  margin: 10px 16px 16px 16px !important;
  border-collapse: collapse !important;
  font-size: 0.9em !important;
  background-color: rgba(255, 255, 255, 0.02) !important;
}

.markdown-body details th {
  background: rgba(100, 120, 150, 0.15) !important;
  padding: 8px 12px !important;
  border: 1px solid rgba(100, 120, 150, 0.3) !important;
  font-weight: 600 !important;
  text-align: left !important;
}

.markdown-body details td {
  padding: 8px 12px !important;
  border: 1px solid rgba(100, 120, 150, 0.2) !important;
  line-height: 1.5 !important;
}

/* 偶数行微调底色增强可读性 */
.markdown-body details tr:nth-child(even) td {
  background-color: rgba(100, 120, 150, 0.03) !important;
}