/* ========== 容器与布局 ========== */
.soul-container {
  max-width: 100%;
  font-family: 'Microsoft YaHei', 'PingFang SC', sans-serif;
  line-height: 1.8;
  color: #2c3e50;
}

/* ========== 顶部状态栏 ========== */
.soul-top-bar {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  padding: 12px 20px;
  border-radius: 12px 12px 0 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.95em;
  box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

.soul-top-bar .item {
  display: flex;
  align-items: center;
  gap: 6px;
}

.soul-top-bar .icon {
  font-size: 1.1em;
}

/* ========== 正文区域 ========== */
.soul-text {
  background: #ffffff;
  padding: 25px;
  border-left: 3px solid #667eea;
  border-right: 3px solid #667eea;
  min-height: 200px;
}

.soul-text p {
  margin: 0 0 15px 0;
  text-indent: 2em;
}

.soul-text p:last-child {
  margin-bottom: 0;
}

/* ========== 后置状态栏 ========== */
.soul-status {
  background: linear-gradient(to bottom, #f8f9fa, #e9ecef);
  padding: 20px;
  border-radius: 0 0 12px 12px;
  border-top: 2px solid #dee2e6;
}

/* ========== details/summary 美化 ========== */
.soul-status details {
  background: white;
  border: 1px solid #dee2e6;
  border-radius: 8px;
  margin-bottom: 12px;
  overflow: hidden;
  transition: all 0.3s ease;
}

.soul-status details:hover {
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  border-color: #667eea;
}

.soul-status details[open] {
  border-color: #667eea;
}

.soul-status summary {
  background: linear-gradient(135deg, #667eea, #764ba2);
  color: white;
  padding: 12px 18px;
  cursor: pointer;
  font-weight: bold;
  font-size: 1.05em;
  user-select: none;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: background 0.3s ease;
}

.soul-status summary:hover {
  background: linear-gradient(135deg, #5568d3, #6a3f8f);
}

.soul-status summary::before {
  content: '▶';
  display: inline-block;
  transition: transform 0.3s ease;
  font-size: 0.8em;
}

.soul-status details[open] summary::before {
  transform: rotate(90deg);
}

.soul-status details .content {
  padding: 15px 18px;
  background: #fafbfc;
}

/* ========== 信息卡片 ========== */
.soul-card {
  background: white;
  border: 1px solid #e1e4e8;
  border-radius: 6px;
  padding: 12px 15px;
  margin-bottom: 10px;
}

.soul-card:last-child {
  margin-bottom: 0;
}

.soul-card .label {
  color: #667eea;
  font-weight: bold;
  margin-right: 8px;
}

.soul-card .value {
  color: #2c3e50;
}

/* ========== 记忆区 ========== */
.soul-memory {
  background: #fff9e6;
  border-left: 4px solid #ffc107;
  padding: 12px 15px;
  margin-bottom: 10px;
  border-radius: 4px;
}

.soul-memory .time {
  color: #856404;
  font-size: 0.9em;
  font-weight: bold;
  margin-bottom: 5px;
}

.soul-memory .event {
  color: #533f03;
  line-height: 1.6;
}

/* ========== 推荐选项 ========== */
.soul-options {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 10px;
  margin-top: 15px;
}

.soul-option {
  background: linear-gradient(135deg, #667eea, #764ba2);
  color: white;
  padding: 10px 15px;
  border-radius: 8px;
  text-align: center;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 5px rgba(102, 126, 234, 0.3);
}

.soul-option:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.5);
}

/* ========== 隐藏元素（用于触发世界书） ========== */
.soul-hidden {
  display: none;
}

/* ========== 响应式设计 ========== */
@media (max-width: 768px) {
  .soul-top-bar {
    flex-direction: column;
    gap: 8px;
    align-items: flex-start;
  }
  
  .soul-text {
    padding: 18px;
  }
  
  .soul-status {
    padding: 15px;
  }
  
  .soul-options {
    grid-template-columns: 1fr;
  }
}

/* ========== 动画效果 ========== */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.soul-container {
  animation: fadeIn 0.5s ease;
}

/* ========== 滚动条美化 ========== */
.soul-status details .content::-webkit-scrollbar {
  width: 6px;
}

.soul-status details .content::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 3px;
}

.soul-status details .content::-webkit-scrollbar-thumb {
  background: #667eea;
  border-radius: 3px;
}

.soul-status details .content::-webkit-scrollbar-thumb:hover {
  background: #5568d3;
}