/* ========== 全局变量与基础重置 ========== */
:root {
  --bg-deep: #020010;
  --text-primary: #f5f0e8;
  --text-body: #fafaf8;
  --text-secondary: #b0a898;
  --accent-gold: #e8c860;
  --accent-blood: #c04040;
  --accent-neon: #00f0ff;
  --border-subtle: rgba(200,170,100,0.25);
  --glass-bg: rgba(8,6,18,0.88);
  --glass-border: rgba(232,200,96,0.3);
  --state-bg: rgba(14,10,22,0.95);
  --shadow-glow: 0 0 40px rgba(232,200,96,0.1);
  --font-body: 'Noto Serif SC', 'Source Han Serif SC', 'Songti SC', serif;
  --font-ui: 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', sans-serif;
}

* { margin:0; padding:0; box-sizing:border-box; }

body {
  background: var(--bg-deep);
  color: var(--text-primary);
  font-family: var(--font-body);
  line-height: 1.95;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* ========== 强化星空动态背景 ========== */
.narrative-container {
  position: relative;
  min-height: 100vh;
  background: radial-gradient(ellipse at 50% 30%, #0d0d2b 0%, #030310 60%, #000005 100%);
  overflow: hidden;
  isolation: isolate;
}

.narrative-container::before {
  content: '';
  position: fixed;
  top: -50%;
  left: -50%;
  width: 250%;
  height: 250%;
  background-image:
    radial-gradient(1px 1px at 5% 10%, rgba(255,255,255,0.9), transparent),
    radial-gradient(1.5px 1.5px at 15% 25%, rgba(200,220,255,0.7), transparent),
    radial-gradient(0.8px 0.8px at 22% 8%, rgba(255,255,255,0.5), transparent),
    radial-gradient(1.2px 1.2px at 30% 40%, rgba(180,200,255,0.6), transparent),
    radial-gradient(2px 2px at 38% 15%, rgba(255,240,200,0.8), transparent),
    radial-gradient(0.6px 0.6px at 45% 50%, rgba(255,255,255,0.4), transparent),
    radial-gradient(1px 1px at 55% 20%, rgba(200,200,255,0.7), transparent),
    radial-gradient(1.8px 1.8px at 62% 35%, rgba(255,255,255,0.8), transparent),
    radial-gradient(0.7px 0.7px at 70% 12%, rgba(255,240,200,0.5), transparent),
    radial-gradient(1.3px 1.3px at 78% 42%, rgba(200,220,255,0.6), transparent),
    radial-gradient(2.5px 2.5px at 85% 8%, rgba(255,255,255,0.9), transparent),
    radial-gradient(0.9px 0.9px at 92% 28%, rgba(180,200,255,0.5), transparent),
    radial-gradient(1px 1px at 10% 60%, rgba(255,255,255,0.6), transparent),
    radial-gradient(1.6px 1.6px at 25% 75%, rgba(200,220,255,0.7), transparent),
    radial-gradient(0.5px 0.5px at 40% 65%, rgba(255,255,255,0.3), transparent),
    radial-gradient(1px 1px at 58% 70%, rgba(255,240,200,0.6), transparent),
    radial-gradient(2px 2px at 72% 55%, rgba(200,200,255,0.8), transparent),
    radial-gradient(0.8px 0.8px at 88% 68%, rgba(255,255,255,0.5), transparent),
    radial-gradient(1.4px 1.4px at 95% 45%, rgba(180,200,255,0.7), transparent);
  background-size: 45% 45%;
  pointer-events: none;
  z-index: 0;
  animation: starRotateA 200s linear infinite;
}

.narrative-container::after {
  content: '';
  position: fixed;
  top: -50%;
  left: -50%;
  width: 250%;
  height: 250%;
  background-image:
    radial-gradient(0.8px 0.8px at 3% 8%, rgba(255,220,180,0.6), transparent),
    radial-gradient(1.2px 1.2px at 12% 32%, rgba(200,200,255,0.5), transparent),
    radial-gradient(1.8px 1.8px at 20% 5%, rgba(255,255,255,0.7), transparent),
    radial-gradient(0.6px 0.6px at 28% 48%, rgba(180,200,255,0.4), transparent),
    radial-gradient(2.2px 2.2px at 35% 18%, rgba(255,240,200,0.8), transparent),
    radial-gradient(0.9px 0.9px at 42% 55%, rgba(200,200,255,0.6), transparent),
    radial-gradient(1.1px 1.1px at 50% 10%, rgba(255,255,255,0.5), transparent),
    radial-gradient(1.5px 1.5px at 58% 38%, rgba(180,200,255,0.7), transparent),
    radial-gradient(0.7px 0.7px at 65% 22%, rgba(255,220,180,0.5), transparent),
    radial-gradient(2px 2px at 75% 45%, rgba(255,255,255,0.9), transparent),
    radial-gradient(1px 1px at 82% 8%, rgba(200,200,255,0.6), transparent),
    radial-gradient(1.6px 1.6px at 90% 28%, rgba(255,240,200,0.7), transparent),
    radial-gradient(0.5px 0.5px at 8% 72%, rgba(255,255,255,0.3), transparent),
    radial-gradient(1.3px 1.3px at 18% 82%, rgba(200,220,255,0.6), transparent),
    radial-gradient(1.8px 1.8px at 32% 68%, rgba(255,255,255,0.7), transparent),
    radial-gradient(0.7px 0.7px at 48% 78%, rgba(255,220,180,0.4), transparent),
    radial-gradient(2.2px 2.2px at 62% 62%, rgba(200,200,255,0.8), transparent),
    radial-gradient(0.9px 0.9px at 78% 72%, rgba(255,255,255,0.5), transparent),
    radial-gradient(1.4px 1.4px at 88% 55%, rgba(180,200,255,0.7), transparent);
  background-size: 55% 55%;
  pointer-events: none;
  z-index: 0;
  animation: starRotateB 280s linear infinite reverse;
  opacity: 0.7;
}

@keyframes starRotateA {
  from { transform: translate(-25%, -25%) rotate(0deg); }
  to { transform: translate(-25%, -25%) rotate(360deg); }
}

@keyframes starRotateB {
  from { transform: translate(-30%, -30%) rotate(0deg); }
  to { transform: translate(-30%, -30%) rotate(-360deg); }
}

.narrative-content {
  position: relative;
  z-index: 1;
  max-width: 820px;
  margin: 0 auto;
  padding: 36px 28px;
}

/* 通用折叠面板标题 */
details>summary {
  cursor: pointer;
  padding: 11px 16px;
  background: linear-gradient(135deg, #1a0e2e, #161628);
  border-bottom: 1px solid var(--border);
  color: var(--accent2);
  font-weight: 600;
  font-family: var(--font-heading);
  font-size: 0.95rem;
  letter-spacing: 1px;
  transition: all 0.3s ease;
  list-style: none;
  -webkit-user-select: none;
  user-select: none;
}

/* 状态栏标题覆盖为粉色（仅影响主角/固定NPC/随机NPC/行动建议） */
details summary:has(+ .player-status),
details summary:has(+ .npc-fixed-status),
details summary:has(+ .npc-random-status),
details summary:has(+ .action-panel) {
  color: #ff99cc;
  text-shadow: 0 0 8px rgba(255, 153, 204, 0.5);
}

/* 叙事正文/状态栏内部背景（深色半透明） */
details summary+* {
  background: var(--bg-scene);
  padding: 12px 14px;
  border-radius: 0 0 10px 10px;
}

/* 嵌套折叠面板内部更深一点 */
details details summary+* {
  background: rgba(20, 15, 35, 0.55);
}

/* 嵌套折叠面板 */
details details {
  border: 1px dashed var(--border);
  background: rgba(22, 22, 40, 0.5);
  margin: 6px 0;
  border-radius: var(--radius-sm);
}

details details>summary {
  background: rgba(30, 20, 50, 0.6);
  font-size: 0.88rem;
  padding: 9px 13px;
  color: #e0c0e0;
}

details details[open] {
  border-color: var(--border-glow);
  box-shadow: 0 0 12px rgba(100, 60, 130, 0.08);
}

/* 表格 */
details table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
  margin: 4px 0;
}

details table td {
  padding: 6px 10px;
  border-bottom: 1px solid rgba(38, 26, 46, 0.5);
  vertical-align: top;
  color: #e0d0d0;
  line-height: 1.6;
}

details table td:first-child {
  color: var(--accent2);
  font-weight: 600;
  white-space: nowrap;
  width: 30%;
  font-size: 0.82rem;
}

/* 列表 */
ol,
ul {
  padding-left: 20px;
  margin: 8px 0;
}

li {
  margin-bottom: 6px;
  color: #e0d0d0;
  line-height: 1.6;
}


/* =============================================
   对话字体颜色渲染（全浅色·高可见度）
   ============================================= */

/* 主角 - 高亮浅金 */
.dialogue-mc {
  color: #ffe8b0;
  font-weight: 700;
  text-shadow: 0 0 10px rgba(255, 210, 120, 0.55), 0 0 28px rgba(255, 180, 80, 0.25);
  letter-spacing: 0.3px;
}

/* 林雨薇 - 冰蓝 */
.dialogue-lin {
  color: #44ddff;
  font-weight: 700;
  text-shadow: 0 0 12px rgba(68, 221, 255, 0.55), 0 0 30px rgba(0, 180, 220, 0.25);
}

/* 苏婉清 - 暖粉 */
.dialogue-su {
  color: #ffc0ce;
  font-weight: 600;
  text-shadow: 0 0 10px rgba(255, 192, 206, 0.45), 0 0 22px rgba(255, 150, 170, 0.2);
}

/* 秦可儿 - 亮粉 */
.dialogue-qin {
  color: #ff88bb;
  font-weight: 700;
  text-shadow: 0 0 14px rgba(255, 136, 187, 0.6), 0 0 32px rgba(255, 80, 140, 0.3);
}

/* 沈医生 - 青绿 */
.dialogue-shen {
  color: #66ffcc;
  font-weight: 600;
  text-shadow: 0 0 10px rgba(102, 255, 204, 0.4), 0 0 22px rgba(60, 220, 160, 0.2);
}

/* 小薇 - 金色 */
.dialogue-wei {
  color: #ffe066;
  font-weight: 700;
  text-shadow: 0 0 14px rgba(255, 224, 102, 0.55), 0 0 30px rgba(255, 180, 0, 0.25);
}

/* 陈主任 - 珊瑚橙 */
.dialogue-chen {
  color: #ffbb99;
  font-weight: 700;
  text-shadow: 0 0 10px rgba(255, 187, 153, 0.45), 0 0 22px rgba(255, 120, 80, 0.2);
}

/* 随机NPC·羞涩型 - 淡粉 */
.dialogue-random-shy {
  color: #ffc8d4;
  font-weight: 500;
  text-shadow: 0 0 8px rgba(255, 182, 193, 0.4);
  font-style: italic;
}

/* 随机NPC·主动/挑逗型 - 亮紫粉 */
.dialogue-random-bold {
  color: #ff99cc;
  font-weight: 700;
  text-shadow: 0 0 12px rgba(255, 136, 204, 0.5), 0 0 20px rgba(255, 80, 150, 0.25);
}

/* 随机NPC·冷漠/专业型 - 银白 */
.dialogue-random-calm {
  color: #e0dde8;
  font-weight: 500;
  text-shadow: 0 0 6px rgba(208, 208, 216, 0.3);
}

/* 随机NPC·默认 - 淡紫 */
.dialogue-random-default {
  color: #e8d0f0;
  font-weight: 500;
  text-shadow: 0 0 10px rgba(224, 200, 232, 0.35);
}

/* 路人NPC·默认 - 淡灰紫 */
.dialogue-bystander {
  color: #d8c8e8;
  font-weight: 500;
  text-shadow: 0 0 6px rgba(216, 200, 232, 0.25);
}
/* 随机NPC内心想法 - 暗橙黄·可读性优先 */
.dialogue-random-thought {
  color: #e8c080;
  font-weight: 500;
  font-style: italic;
}

/* =============================================
   特殊文本样式
   ============================================= */

/* 校规/官方文件/公告 - 红色 */
.rule-text {
  color: #ff5555;
  font-weight: 700;
  background: rgba(255, 0, 0, 0.1);
  padding: 4px 12px;
  border-radius: 6px;
  border-left: 4px solid #ff4444;
  display: inline-block;
  font-family: var(--font-heading);
  letter-spacing: 0.5px;
  text-shadow: 0 0 8px rgba(255, 68, 68, 0.3);
}

/* 随机事件标题 - 金色闪烁 */
.random-event-banner {
  color: #ffee55;
  font-weight: 700;
  font-size: 1.05rem;
  display: block;
  margin: 14px 0;
  padding: 12px 16px;
  background: rgba(255, 204, 0, 0.08);
  border-radius: 12px;
  border: 2px dashed rgba(255, 204, 0, 0.4);
  text-align: center;
  letter-spacing: 1.5px;
  text-shadow: 0 0 16px rgba(255, 238, 85, 0.5), 0 0 40px rgba(255, 204, 0, 0.2);
  animation: eventPulse 2.5s ease-in-out infinite;
}

@keyframes eventPulse {
  0%, 100% { border-color: rgba(255,204,0,0.4); box-shadow: 0 0 16px rgba(255,204,0,0.08); }
  50% { border-color: rgba(255,204,0,0.75); box-shadow: 0 0 30px rgba(255,204,0,0.15); }
}

/* 好感度变化 - 爱心粉 */
.affection-up {
  color: #ff99bb;
  font-weight: 700;
  font-size: 0.86rem;
  text-shadow: 0 0 8px rgba(255, 153, 187, 0.35);
  padding: 1px 4px;
}

/* 数值变动 - 亮紫 */
.stat-change {
  color: #e088ff;
  font-weight: 700;
  font-size: 0.86rem;
  text-shadow: 0 0 8px rgba(224, 136, 255, 0.35);
  padding: 1px 4px;
}

/* 系统提示/警告 - 橙色 */
.system-alert {
  color: #ffbb44;
  font-weight: 700;
  font-size: 0.9rem;
  background: rgba(255, 153, 0, 0.08);
  padding: 5px 12px;
  border-radius: 8px;
  display: inline-block;
  border: 1px solid rgba(255, 153, 0, 0.2);
  text-shadow: 0 0 6px rgba(255, 187, 68, 0.25);
}



/* =============================================
   开场场景 (使用无包裹纯文本，仅简单的换行和字号区分)
   ============================================= */
.scene-time {
  color: #ffcc00;
  font-weight: bold;
  font-size: 1.1rem;
  margin-bottom: 6px;
}

.scene-location {
  color: #ff9966;
  font-weight: bold;
  font-size: 1rem;
  margin-bottom: 6px;
}

.scene-environment {
  color: #66ddcc;
  font-size: 0.9rem;
  margin-bottom: 10px;
  line-height: 1.6;
}

/* =============================================
   主角状态栏
   ============================================= */
.player-status {
  background: linear-gradient(145deg, #1a1a2e, #141428);
  border: 2px solid #e91e63;
  border-radius: 14px;
  padding: 14px;
  margin: 10px 0;
  box-shadow: 0 0 28px rgba(233, 30, 99, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.02);
}

.player-status .ps-header {
  display: flex; align-items: center; gap: 10px;
  margin-bottom: 10px; border-bottom: 1px solid #2e1a3a; padding-bottom: 8px;
  flex-wrap: wrap;
}
.player-status .ps-name {
  font-size: 1.15rem; font-weight: bold; color: #ff5080;
  text-shadow: 0 0 14px rgba(255, 80, 128, 0.5);
}
.player-status .ps-badge {
  background: rgba(233,30,99,0.18); padding: 2px 10px; border-radius: 12px;
  font-size: 0.78rem; color: #ff6699; font-weight: 600;
}

.player-status .ps-basic {
  display: flex; flex-wrap: wrap; gap: 5px 14px; margin-bottom: 8px;
  font-size: 0.82rem; color: #e8d8d8;
}
.player-status .ps-attr-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px;
  background: rgba(233,30,99,0.05); border-radius: 8px; padding: 10px; margin-bottom: 8px;
}
.player-status .ps-attr-item { text-align: center; }
.player-status .ps-attr-label { color: #ffaa66; font-weight: bold; font-size: 0.74rem; display: block; margin-bottom: 2px; }
.player-status .ps-attr-value { color: #fff; font-size: 0.95rem; font-weight: bold; }
.player-status .ps-attr-sub { color: #d0c0c0; font-size: 0.74rem; display: block; }

.player-status .ps-state-bar {
  background: rgba(255,64,129,0.05); border-left: 3px solid #e91e63;
  border-radius: 0 6px 6px 0; padding: 6px 10px; margin-bottom: 8px;
  font-size: 0.82rem; display: flex; flex-wrap: wrap; gap: 5px 12px; color: #e8d8d8;
}
.player-status .label-yellow { color: #ffcc00; font-weight: bold; }
.player-status .label-magenta { color: #dd88ff; font-weight: bold; }

.player-status .ps-private {
  background: rgba(200,80,120,0.06); border-radius: 6px; padding: 8px 10px;
  margin-bottom: 6px; font-size: 0.82rem; color: #d8c8c8;
}
.player-status .label-pink { color: #ff88aa; font-weight: bold; }
.player-status .body-parts { display: block; margin-top: 4px; color: #d0c0c0; font-size: 0.8rem; }

.player-status .ps-thought {
  color: #ffccd5; font-size: 0.86rem; margin: 0; font-style: italic;
}
.player-status .label-thought { font-weight: bold; font-style: normal; color: #ffb6c1; }


/* =============================================
   固定NPC状态栏
   ============================================= */
.npc-fixed-status {
  background: linear-gradient(145deg, #1a1028, #0f0f20);
  border: 1px solid #3a1a4a; border-radius: 14px; padding: 14px; margin: 10px 0;
  box-shadow: 0 0 22px rgba(200, 100, 255, 0.07);
}
.npc-fixed-status .nfs-header {
  display: flex; align-items: center; gap: 10px; margin-bottom: 8px;
  border-bottom: 1px solid #3a1a4a; padding-bottom: 6px; flex-wrap: wrap;
}
.npc-fixed-status .nfs-name { font-size: 1.1rem; font-weight: bold; text-shadow: 0 0 10px currentColor; }
.npc-fixed-status .nfs-badge {
  background: rgba(255,255,255,0.05); padding: 2px 10px; border-radius: 12px;
  font-size: 0.75rem; color: #d0c0d0; font-weight: 500;
}
.npc-fixed-status .nfs-basic {
  display: flex; flex-wrap: wrap; gap: 4px 14px; margin-bottom: 8px;
  font-size: 0.8rem; color: #e0d0d0;
}
.npc-fixed-status .nfs-state-bar {
  background: rgba(255,100,150,0.05); border-left: 3px solid #ff6699;
  border-radius: 0 6px 6px 0; padding: 6px 10px; margin-bottom: 8px;
  font-size: 0.8rem; display: flex; flex-wrap: wrap; gap: 5px 12px; color: #e8d8d8;
}
.npc-fixed-status .nfs-private {
  background: rgba(200,100,200,0.05); border-radius: 6px; padding: 8px 10px;
  margin-bottom: 6px; font-size: 0.8rem; color: #d0c0d0;
}
.npc-fixed-status .label-purple { color: #eeaadd; font-weight: bold; }
.npc-fixed-status .nfs-thought { color: #ffccd5; font-size: 0.84rem; margin: 0; font-style: italic; }


/* =============================================
   随机NPC状态栏
   ============================================= */
.npc-random-status {
  background: linear-gradient(145deg, #1a1028, #121022);
  border: 1px dashed #6a2a6a; border-radius: 12px; padding: 12px; margin: 8px 0;
  box-shadow: 0 0 14px rgba(180, 100, 220, 0.05);
}
.npc-random-status .nrs-header {
  display: flex; align-items: center; gap: 8px; margin-bottom: 6px;
  border-bottom: 1px dashed #3a1a3a; padding-bottom: 5px; flex-wrap: wrap;
}
.npc-random-status .nrs-name { font-size: 1rem; font-weight: bold; color: #eeaadd; text-shadow: 0 0 8px rgba(221,160,221,0.35); }
.npc-random-status .nrs-badge {
  background: rgba(221,160,221,0.12); padding: 1px 8px; border-radius: 10px;
  font-size: 0.72rem; color: #d0b8d0; font-weight: 500;
}
.npc-random-status .nrs-info {
  display: flex; flex-wrap: wrap; gap: 3px 12px; margin-bottom: 6px;
  font-size: 0.78rem; color: #d8c8d8;
}
.npc-random-status .nrs-state {
  background: rgba(200,150,220,0.05); border-radius: 6px; padding: 6px 10px;
  font-size: 0.78rem; color: #e0d0e0;
}

/* 星记忆回廊 */
details summary:has(+ div) {
  color: #7ec8ff;
  text-shadow: 0 0 8px rgba(126, 200, 255, 0.5);
  font-weight: 700;
  font-size: 0.9rem;
  letter-spacing: 0.5px;
}
details summary:has(+ div):hover {
  color: #a0d8ff;
  text-shadow: 0 0 14px rgba(160, 216, 255, 0.7);
}

/* =============================================
   行动建议面板（12条）
   ============================================= */
.action-panel {
  background: linear-gradient(135deg, #10081c, #0a0514);
  border: 2px solid #ff4081; border-radius: 16px; padding: 16px; margin: 16px 0;
  box-shadow: 0 0 32px rgba(255,64,129,0.15), 0 0 80px rgba(255,64,129,0.04), inset 0 1px 0 rgba(255,255,255,0.02);
  position: relative; overflow: hidden; z-index: 1;
}
.action-panel::before {
  content: ''; position: absolute; top: 0; left: 20%; width: 60%; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255,64,129,0.5), rgba(255,182,193,0.5), rgba(255,64,129,0.5), transparent);
}
.action-panel .ap-title {
  color: #ff6699; font-weight: bold; font-size: 1.05rem; text-align: center;
  margin-bottom: 12px; letter-spacing: 2px;
  text-shadow: 0 0 14px rgba(255,64,129,0.6), 0 0 40px rgba(255,64,129,0.2);
}
.action-panel ol { list-style: none; padding: 0; margin: 0; }
.action-panel ol li {
  border-radius: 10px; padding: 10px 14px; margin-bottom: 8px; color: #f0e0e0;
  border-left: 3px solid #e91e63; font-size: 0.9rem; line-height: 1.5;
  transition: all 0.25s ease; cursor: pointer; user-select: none;
  -webkit-tap-highlight-color: rgba(255,64,129,0.2); position: relative;
}
.action-panel ol li:last-child { margin-bottom: 0; }

.action-panel ol li:nth-child(1) { background: rgba(255,64,129,0.06); border-left-color: #ffcc00; }
.action-panel ol li:nth-child(2) { background: rgba(255,64,129,0.04); border-left-color: #ff69b4; }
.action-panel ol li:nth-child(3) { background: rgba(255,64,129,0.06); border-left-color: #dda0dd; }
.action-panel ol li:nth-child(4) { background: rgba(255,64,129,0.04); border-left-color: #ff9966; }
.action-panel ol li:nth-child(5) { background: rgba(255,64,129,0.06); border-left-color: #ffb6c1; }
.action-panel ol li:nth-child(6) { background: rgba(255,64,129,0.04); border-left-color: #7fffd4; }
.action-panel ol li:nth-child(7) { background: rgba(255,64,129,0.06); border-left-color: #ffcc00; }
.action-panel ol li:nth-child(8) { background: rgba(255,64,129,0.04); border-left-color: #ff69b4; }
.action-panel ol li:nth-child(9) { background: rgba(255,64,129,0.06); border-left-color: #dda0dd; }
.action-panel ol li:nth-child(10) { background: rgba(255,64,129,0.04); border-left-color: #ff9966; }
.action-panel ol li:nth-child(11) { background: rgba(255,64,129,0.06); border-left-color: #ffb6c1; }
.action-panel ol li:nth-child(12) { background: rgba(255,64,129,0.04); border-left-color: #7fffd4; }

.action-panel ol li:active { transform: scale(0.97); filter: brightness(1.3); }
.action-panel ol li.selected-action {
  background: rgba(255,64,129,0.2) !important; border-left-color: #fff !important;
  box-shadow: 0 0 16px rgba(255,64,129,0.4); color: #fff; font-weight: bold;
}
.action-panel ol li.selected-action::after { content: ' ✅'; font-size: 0.8rem; }

.action-panel .ap-tag { font-weight: bold; margin-right: 6px; font-size: 0.78rem; letter-spacing: 0.5px; }
.action-panel ol li:nth-child(1) .ap-tag { color: #ffcc00; }
.action-panel ol li:nth-child(2) .ap-tag { color: #ff69b4; }
.action-panel ol li:nth-child(3) .ap-tag { color: #dda0dd; }
.action-panel ol li:nth-child(4) .ap-tag { color: #ff9966; }
.action-panel ol li:nth-child(5) .ap-tag { color: #ffb6c1; }
.action-panel ol li:nth-child(6) .ap-tag { color: #7fffd4; }
.action-panel ol li:nth-child(7) .ap-tag { color: #ffcc00; }
.action-panel ol li:nth-child(8) .ap-tag { color: #ff69b4; }
.action-panel ol li:nth-child(9) .ap-tag { color: #dda0dd; }
.action-panel ol li:nth-child(10) .ap-tag { color: #ff9966; }
.action-panel ol li:nth-child(11) .ap-tag { color: #ffb6c1; }
.action-panel ol li:nth-child(12) .ap-tag { color: #7fffd4; }

.action-panel .ap-footer { color: #a898a8; text-align: center; font-size: 0.82rem; margin-top: 12px; font-style: italic; }


/* ========== 强化叙事正文（白色修正） ========== */
.narrative-text {
  font-size: 1.06em;
  line-height: 2.2;
  letter-spacing: 0.03em;
  word-break: break-word;
  color: #fafaf8;
}

.narrative-text p {
  margin-bottom: 1.3em;
  text-indent: 2em;
  color: #fafaf8;
}

.narrative-text p:first-of-type { text-indent: 0; }

.narrative-text .environment-desc {
  color: #d8d8d0;
  font-style: italic;
  border-left: 3px solid rgba(232,200,96,0.25);
  padding-left: 18px;
  margin: 18px 0;
  background: rgba(232,200,96,0.03);
  border-radius: 0 4px 4px 0;
}

.narrative-text .sensory-closeup {
  color: #f0e8e0;
  border-left: 3px solid rgba(200,100,80,0.4);
  padding-left: 18px;
  margin: 18px 0;
  background: rgba(200,100,80,0.03);
  border-radius: 0 4px 4px 0;
}

.narrative-text .explicit-content {
  color: #faf5f0;
  border-left: 3px solid rgba(220,80,100,0.5);
  padding-left: 18px;
  margin: 18px 0;
  background: rgba(220,80,100,0.04);
  border-radius: 0 4px 4px 0;
}

/* ========== 强化开场场景 ========== */
.opening-scene {
  border: 1px solid var(--glass-border);
  border-radius: 8px;
  padding: 22px;
  margin-bottom: 28px;
  background: rgba(18,14,30,0.92);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 0 25px rgba(200,160,60,0.06);
}

.opening-scene .scene-time {
  font-family: var(--font-ui);
  font-size: 0.84em;
  color: #80d8ff;
  margin-bottom: 6px;
}

.opening-scene .scene-location {
  font-family: var(--font-ui);
  font-size: 0.84em;
  color: #80ffb0;
  margin-bottom: 6px;
}

.opening-scene .scene-characters {
  font-family: var(--font-ui);
  font-size: 0.84em;
  color: #ffb0cc;
}

/* ========== 响应式适配 ========== */
@media (max-width: 768px) {
  .narrative-content {
    max-width: 100%;
    padding: 22px 14px;
  }
  .state-panel summary {
    padding: 13px 16px;
    font-size: 0.8em;
  }
  .state-content {
    padding: 14px 16px;
  }
  .state-item strong {
    min-width: 65px;
    font-size: 0.76em;
  }
}

@media (max-width: 480px) {
  .narrative-content {
    padding: 16px 8px;
  }
  .state-panel summary {
    padding: 11px 12px;
    font-size: 0.76em;
  }
  .state-content {
    padding: 12px 12px;
    font-size: 0.78em;
  }
  .state-item {
    flex-direction: column;
    gap: 2px;
  }
  .narrative-text {
    font-size: 0.88em;
    line-height: 1.85;
  }
  .narrative-text p {
    text-indent: 1.5em;
  }
}

/* ========== 状态栏标题 · 强制高亮 ========== */
/* 用法：替换原CSS中.state-panel summary相关选择器块 */

.state-panel summary {
  padding: 15px 22px;
  cursor: pointer;
  font-family: var(--font-ui);
  font-size: 0.92em;
  font-weight: 800;
  color: #fffde0;
  background: linear-gradient(
    180deg,
    rgba(232,200,96,0.15) 0%,
    rgba(232,200,96,0.04) 100%
  );
  letter-spacing: 0.1em;
  transition: all 0.3s cubic-bezier(0.4,0,0.2,1);
  user-select: none;
  border-left: 3px solid transparent;
  position: relative;
  text-shadow:
    0 0 8px rgba(255,250,200,0.7),
    0 0 20px rgba(255,240,160,0.5),
    0 0 35px rgba(232,200,96,0.3);
}

.state-panel summary:hover {
  color: #ffffff;
  background: linear-gradient(
    180deg,
    rgba(232,200,96,0.25) 0%,
    rgba(232,200,96,0.08) 100%
  );
  text-shadow:
    0 0 12px rgba(255,255,255,0.9),
    0 0 28px rgba(255,240,160,0.7),
    0 0 50px rgba(232,200,96,0.5);
  border-left-color: transparent;
}

.state-panel summary::after {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  width: 4px;
  background: #fffde0;
  transform: scaleY(0);
  transition: transform 0.3s ease;
  box-shadow: 0 0 10px rgba(255,250,200,0.8);
}

.state-panel summary:hover::after {
  transform: scaleY(1);
}

.state-panel summary::marker {
  font-size: 0.7em;
  color: #fffde0;
  content: '◆ ';
  text-shadow: 0 0 8px rgba(255,250,200,0.6);
}

/* 叙事插图 */
.narrative-image {
  margin: 20px 0;
  text-align: center;
}
.narrative-image img {
  max-width: 100%;
  border-radius: 12px;
  box-shadow: 0 0 30px rgba(233, 30, 99, 0.2);
}
.image-caption {
  display: block;
  margin-top: 8px;
  font-size: 0.72rem;
  color: #a09888;
  font-style: italic;
  font-family: var(--font-ui);
}
/* 乐子人点评栏 · 强制字体颜色 */
.commentary-inline,
.commentary-inline p,
.commentary-inline span {
  color: #f0e0d0 !important;
}