/* 项目帮助/流程说明页样式 */
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
  font-family: "Microsoft Yahei", system-ui, sans-serif;
  background: #f0f4f8; color: #1e293b; line-height: 1.8;
}
.header {
  background: linear-gradient(135deg, #1e3a5f, #2d6a9f);
  color: #fff; text-align: center; padding: 40px 20px 32px;
}
.header h1 { font-size: 26px; font-weight: 700; margin-bottom: 8px; }
.header p { font-size: 15px; opacity: 0.85; }

.container { max-width: 900px; margin: 0 auto; padding: 32px 20px 60px; }

/* 流程图区域 */
.flow-section { margin-bottom: 40px; }
.flow-section h2 {
  font-size: 20px; color: #1e3a5f; margin-bottom: 20px;
  padding-left: 12px; border-left: 4px solid #2d6a9f;
}
.flow-diagram {
  display: flex; align-items: center; justify-content: center;
  gap: 0; flex-wrap: nowrap; margin: 24px 0; overflow-x: auto;
}
.flow-step {
  background: #fff; border-radius: 12px; padding: 20px 18px;
  min-width: 170px; width: 170px; text-align: center;
  box-shadow: 0 2px 8px rgba(0,0,0,0.07);
  position: relative; flex-shrink: 0;
  cursor: pointer; transition: transform 0.2s, box-shadow 0.2s;
}
.flow-step:hover { transform: translateY(-4px); box-shadow: 0 6px 20px rgba(0,0,0,0.12); }
.flow-step.active { border: 2px solid #2d6a9f; }
.flow-step .step-icon { font-size: 36px; margin-bottom: 8px; }
.flow-step .step-title { font-size: 15px; font-weight: 600; color: #1e3a5f; margin-bottom: 4px; }
.flow-step .step-desc { font-size: 12px; color: #6b7280; }
.flow-arrow {
  display: flex; align-items: center; font-size: 28px; color: #93c5fd;
  padding: 0 8px; font-weight: bold; user-select: none;
}

/* 详情面板 */
.detail-panel {
  background: #fff; border-radius: 12px; padding: 24px 28px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.06);
  margin-top: 16px; min-height: 120px; border-left: 4px solid #2d6a9f;
}
.detail-panel h3 { font-size: 16px; color: #1e3a5f; margin-bottom: 10px; }
.detail-panel p { font-size: 14px; color: #374151; margin-bottom: 8px; }
.detail-panel .code-block {
  background: #f8fafc; border: 1px solid #e2e8f0; border-radius: 8px;
  padding: 12px 16px; font-family: "Consolas", monospace; font-size: 13px;
  color: #334155; overflow-x: auto; margin: 8px 0; white-space: pre;
}
.highlight { color: #2563eb; font-weight: 600; }
.tag {
  display: inline-block; background: #dbeafe; color: #1d4ed8;
  padding: 2px 8px; border-radius: 4px; font-size: 12px; font-weight: 500;
}

/* 对比表格 */
.compare-table {
  width: 100%; border-collapse: collapse; margin: 16px 0;
  background: #fff; border-radius: 8px; overflow: hidden;
  box-shadow: 0 1px 4px rgba(0,0,0,0.06);
}
.compare-table th {
  background: #1e3a5f; color: #fff; padding: 12px 16px;
  text-align: left; font-size: 14px;
}
.compare-table td {
  padding: 10px 16px; border-bottom: 1px solid #f1f5f9;
  font-size: 13px; color: #374151;
}
.compare-table tr:nth-child(even) td { background: #f8fafc; }

/* 动画演示 */
.demo-area {
  background: #fff; border-radius: 12px; padding: 24px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.06); margin-top: 20px;
}
.demo-btn {
  padding: 10px 24px; background: #2d6a9f; color: #fff; border: none;
  border-radius: 8px; font-size: 14px; font-weight: 600; cursor: pointer;
  transition: background 0.2s;
}
.demo-btn:hover { background: #1e3a5f; }
.demo-btn:disabled { background: #9ca3af; cursor: not-allowed; }
.demo-log {
  margin-top: 12px; background: #f8fafc; border: 1px solid #e2e8f0;
  border-radius: 8px; padding: 12px 16px; font-size: 13px; color: #374151;
  max-height: 200px; overflow-y: auto; font-family: "Consolas", monospace;
}
.log-line { margin-bottom: 4px; }
.log-line.send { color: #2563eb; }
.log-line.receive { color: #16a34a; }
.log-line.info { color: #9333ea; }

@media (max-width: 768px) {
  .flow-diagram { flex-wrap: wrap; justify-content: center; }
  .flow-arrow { padding: 4px 6px; font-size: 22px; }
  .flow-step { min-width: 140px; width: 140px; padding: 14px 12px; }
  .flow-step .step-icon { font-size: 28px; }
  .flow-step .step-title { font-size: 13px; }
}
