/* 帮助系统样式 - 白底黑字主题 */

/* 帮助模态框 */
.help-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.help-modal.show {
  opacity: 1;
}

.help-modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: transparent;
}

.help-modal-container {
  position: relative;
  width: 90%;
  max-width: 1200px;
  height: 80%;
  max-height: 800px;
  background: #ffffff;
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid #e5e7eb;
  transform: scale(0.9);
  transition: transform 0.3s ease;
}

.help-modal.show .help-modal-container {
  transform: scale(1);
}

/* 模态框头部 */
.help-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  background: #f8fafc;
  border-bottom: 1px solid #e5e7eb;
}

.help-modal-header h2 {
  margin: 0;
  color: #1f2937;
  font-size: 1.5rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 12px;
}

.help-modal-header h2 i {
  color: #3b82f6;
}

.help-modal-close {
  background: none;
  border: none;
  color: #6b7280;
  font-size: 1.2rem;
  cursor: pointer;
  padding: 8px;
  border-radius: 6px;
  transition: all 0.2s ease;
}

.help-modal-close:hover {
  background: #fee2e2;
  color: #dc2626;
}

/* 模态框主体 */
.help-modal-body {
  display: flex;
  flex: 1;
  overflow: hidden;
}

/* 侧边栏 */
.help-sidebar {
  width: 320px;
  background: #f9fafb;
  border-right: 1px solid #e5e7eb;
  display: flex;
  flex-direction: column;
}

/* 搜索框 */
.help-search {
  position: relative;
  padding: 20px;
  border-bottom: 1px solid #e5e7eb;
}

.help-search input {
  width: 100%;
  padding: 12px 16px 12px 40px;
  background: #ffffff;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  color: #1f2937;
  font-size: 14px;
  transition: border-color 0.2s ease;
}

.help-search input:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.help-search input::placeholder {
  color: #9ca3af;
}

.help-search i {
  position: absolute;
  left: 32px;
  top: 50%;
  transform: translateY(-50%);
  color: #9ca3af;
  font-size: 14px;
}

/* 分类容器 */
.help-categories {
  flex: 1;
  overflow-y: auto;
  padding: 8px 0;
}

.help-categories::-webkit-scrollbar {
  width: 6px;
}

.help-categories::-webkit-scrollbar-track {
  background: transparent;
}

.help-categories::-webkit-scrollbar-thumb {
  background: #d1d5db;
  border-radius: 3px;
}

.help-categories::-webkit-scrollbar-thumb:hover {
  background: #9ca3af;
}

/* 分类 */
.help-category {
  margin-bottom: 8px;
}

.help-category-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 20px;
  font-weight: 600;
  color: #1f2937;
  font-size: 14px;
  border-left: 3px solid #3b82f6;
  background: #eff6ff;
}

.help-category-header i {
  font-size: 16px;
  color: #3b82f6;
}

/* 主题列表 */
.help-category-topics {
  padding-left: 8px;
}

.help-topic {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 20px;
  cursor: pointer;
  color: #6b7280;
  font-size: 14px;
  transition: all 0.2s ease;
  border-radius: 6px;
  margin: 2px 12px;
}

.help-topic:hover {
  background: #eff6ff;
  color: #1f2937;
}

.help-topic.active {
  background: #dbeafe;
  color: #1d4ed8;
  font-weight: 500;
}

.help-topic i {
  font-size: 14px;
  width: 16px;
  text-align: center;
}

/* 无搜索结果 */
.help-no-results {
  text-align: center;
  padding: 40px 20px;
  color: #9ca3af;
}

.help-no-results i {
  font-size: 2rem;
  margin-bottom: 12px;
  color: #d1d5db;
}

.help-no-results p {
  margin: 8px 0 4px;
  font-weight: 500;
  color: #6b7280;
}

.help-no-results small {
  font-size: 12px;
}

/* 内容区域 */
.help-content {
  flex: 1;
  padding: 0;
  overflow-y: auto;
  background: #ffffff;
}

.help-content::-webkit-scrollbar {
  width: 8px;
}

.help-content::-webkit-scrollbar-track {
  background: transparent;
}

.help-content::-webkit-scrollbar-thumb {
  background: #d1d5db;
  border-radius: 4px;
}

.help-content::-webkit-scrollbar-thumb:hover {
  background: #9ca3af;
}

/* 欢迎页面 */
.help-welcome {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  text-align: center;
  padding: 40px;
}

.welcome-icon {
  width: 80px;
  height: 80px;
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 24px;
}

.welcome-icon i {
  font-size: 2rem;
  color: white;
}

.help-welcome h3 {
  margin: 0 0 12px;
  color: #1f2937;
  font-size: 1.5rem;
}

.help-welcome p {
  margin: 0 0 32px;
  color: #6b7280;
  font-size: 1rem;
}

.quick-links {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  justify-content: center;
}

.quick-link-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  background: #f3f4f6;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  color: #374151;
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
}

.quick-link-btn:hover {
  background: #e5e7eb;
  border-color: #9ca3af;
  transform: translateY(-1px);
}

/* 主题内容 */
.help-topic-content {
  padding: 32px;
}

.help-topic-header {
  margin-bottom: 32px;
  padding-bottom: 20px;
  border-bottom: 1px solid #e5e7eb;
}

.help-topic-header h1 {
  margin: 0 0 12px;
  color: #1f2937;
  font-size: 2rem;
  font-weight: 600;
}

.help-topic-description {
  margin: 0;
  color: #6b7280;
  font-size: 1.1rem;
  line-height: 1.6;
}

/* 章节 */
.help-sections {
  margin-bottom: 32px;
}

.help-section {
  margin-bottom: 32px;
}

.help-section h3 {
  margin: 0 0 16px;
  color: #1f2937;
  font-size: 1.3rem;
  font-weight: 600;
}

.help-section-content {
  color: #374151;
  line-height: 1.7;
  font-size: 15px;
}

.help-section-content p {
  margin: 0 0 16px;
}

.help-section-content ul,
.help-section-content ol {
  margin: 0 0 16px;
  padding-left: 24px;
}

.help-section-content li {
  margin-bottom: 8px;
}

.help-section-content strong {
  color: #1f2937;
  font-weight: 600;
}

.help-section-content code {
  background: #f3f4f6;
  padding: 2px 6px;
  border-radius: 4px;
  font-family: 'Courier New', monospace;
  font-size: 13px;
  color: #1d4ed8;
  border: 1px solid #e5e7eb;
}

/* 步骤样式 */
.help-steps {
  margin: 20px 0;
}

.step {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 24px;
  padding: 16px;
  background: #f9fafb;
  border-radius: 8px;
  border-left: 3px solid #3b82f6;
  border: 1px solid #e5e7eb;
}

.step-number {
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 600;
  font-size: 14px;
  flex-shrink: 0;
}

.step-content h4 {
  margin: 0 0 8px;
  color: #1f2937;
  font-size: 1.1rem;
}

.step-content p {
  margin: 0;
  color: #6b7280;
  line-height: 1.6;
}

/* 比较表格 */
.comparison-table {
  margin: 20px 0;
  overflow-x: auto;
}

.comparison-table table {
  width: 100%;
  border-collapse: collapse;
  background: #ffffff;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid #e5e7eb;
}

.comparison-table th,
.comparison-table td {
  padding: 12px 16px;
  text-align: left;
  border-bottom: 1px solid #e5e7eb;
}

.comparison-table th {
  background: #f9fafb;
  color: #1f2937;
  font-weight: 600;
}

.comparison-table td {
  color: #374151;
}

.comparison-table tr:last-child td {
  border-bottom: none;
}

/* 代码示例 */
.code-example {
  background: #f9fafb;
  border-radius: 8px;
  padding: 16px;
  margin: 16px 0;
  border-left: 3px solid #3b82f6;
  border: 1px solid #e5e7eb;
}

.code-example code {
  display: block;
  font-family: 'Courier New', monospace;
  font-size: 14px;
  color: #1d4ed8;
  margin-bottom: 8px;
  background: none;
  padding: 0;
  border: none;
}

.code-example p {
  margin: 0;
  color: #6b7280;
  font-size: 13px;
}

/* FAQ样式 */
.faq-item {
  background: #f9fafb;
  border-radius: 8px;
  padding: 20px;
  margin-bottom: 16px;
  border-left: 3px solid #10b981;
  border: 1px solid #e5e7eb;
}

.faq-item h4 {
  margin: 0 0 12px;
  color: #1f2937;
  font-size: 1.1rem;
}

.faq-item p {
  margin: 0;
  color: #374151;
  line-height: 1.6;
}

/* 图片 */
.help-images {
  margin-top: 32px;
}

.help-image {
  margin-bottom: 24px;
  text-align: center;
}

.help-image img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  cursor: pointer;
  transition: transform 0.2s ease;
  border: 1px solid #e5e7eb;
}

.help-image img:hover {
  transform: scale(1.02);
}

.help-image-caption {
  margin: 12px 0 0;
  color: #6b7280;
  font-size: 14px;
  font-style: italic;
}

/* 图片模态框 */
.image-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10001;
  cursor: pointer;
}

.image-modal-content {
  position: relative;
  max-width: 90%;
  max-height: 90%;
  cursor: default;
}

.image-modal-content img {
  max-width: 100%;
  max-height: 100%;
  border-radius: 8px;
}

.image-modal-close {
  position: absolute;
  top: -40px;
  right: 0;
  background: rgba(0, 0, 0, 0.7);
  border: none;
  color: white;
  font-size: 1.2rem;
  cursor: pointer;
  padding: 8px 12px;
  border-radius: 6px;
  transition: background 0.2s ease;
}

.image-modal-close:hover {
  background: rgba(220, 38, 38, 0.8);
}

/* 响应式设计 */
@media (max-width: 768px) {
  .help-modal-container {
    width: 95%;
    height: 90%;
    margin: 20px;
  }

  .help-modal-body {
    flex-direction: column;
  }

  .help-sidebar {
    width: 100%;
    height: 200px;
    border-right: none;
    border-bottom: 1px solid #e5e7eb;
  }

  .help-content {
    flex: 1;
  }

  .help-topic-content {
    padding: 20px;
  }

  .help-topic-header h1 {
    font-size: 1.5rem;
  }

  .quick-links {
    flex-direction: column;
    align-items: center;
  }

  .quick-link-btn {
    width: 200px;
    justify-content: center;
  }

  .step {
    flex-direction: column;
    text-align: center;
  }

  .comparison-table {
    font-size: 12px;
  }
}

@media (max-width: 480px) {
  .help-modal-container {
    width: 100%;
    height: 100%;
    border-radius: 0;
  }

  .help-modal-header {
    padding: 16px 20px;
  }

  .help-modal-header h2 {
    font-size: 1.2rem;
  }

  .help-topic-content {
    padding: 16px;
  }
}