﻿/* ==========================================================
   上线性能与顺滑度增强引擎 (Smoothness & Performance Optimization)
   ========================================================== */
html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  width: 100%;
}

*, *::before, *::after {
  box-sizing: border-box;
}

/* 硬件加速与流畅悬停 */
a, button, .media-news-card, .btn-media-primary, .btn-media-secondary, .faq-card, .intro-panel {
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  transform: translateZ(0);
}

/* 移动端平滑滚动与防抖 */
.table-wrapper, .table-container, .code-box, pre {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
}

/* 媒体图片防溢出与自适应 */
img, svg, video, canvas {
  max-width: 100%;
  height: auto;
  display: block;
}

/* 消除点击高亮延迟 */
a, button, input, select, textarea {
  -webkit-tap-highlight-color: transparent;
}

/* ==========================================================
   Notion 风格知识库，简洁模块化 (Notion-Inspired Clean Modular Theme)
   ========================================================== */

:root {
  --bg-main: #ffffff;
  --bg-page: #ffffff;
  --bg-surface: #f7f7f5;
  --bg-card: #ffffff;
  --bg-card-hover: #fbfbfa;
  --bg-callout: #f1f1ef;
  --border-color: #e9e9e8;
  --border-subtle: #eaeaea;
  --border-active: #d3d3d1;
  --text-main: #37352f;
  --text-muted: #787774;
  --text-dim: #9b9a97;
  
  /* Notion 标签色系 */
  --tag-gray-bg: #e3e2de;
  --tag-gray-text: #32302c;
  --tag-brown-bg: #eee0da;
  --tag-brown-text: #442a1e;
  --tag-orange-bg: #fadec9;
  --tag-orange-text: #49290e;
  --tag-yellow-bg: #fdecc8;
  --tag-yellow-text: #402c1b;
  --tag-green-bg: #dbeddb;
  --tag-green-text: #1c3829;
  --tag-blue-bg: #d3e5ef;
  --tag-blue-text: #183347;
  --tag-purple-bg: #e8deee;
  --tag-purple-text: #412454;
  --tag-pink-bg: #f5e0e9;
  --tag-pink-text: #4c2337;
  
  --font-base: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, "Apple Color Emoji", Arial, sans-serif;
  --font-mono: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, Courier, monospace;
  --radius-sm: 4px;
  --radius-md: 6px;
  --radius-lg: 10px;
  --shadow-sm: 0 1px 2px rgba(15, 15, 15, 0.05);
  --shadow-card: 0 1px 3px rgba(15, 15, 15, 0.08);
  --shadow-hover: 0 4px 12px rgba(15, 15, 15, 0.08);
  --transition: all 0.15s ease-in-out;
}

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

body {
  background-color: var(--bg-main);
  color: var(--text-main);
  font-family: var(--font-base);
  line-height: 1.65;
  font-size: 15px;
  -webkit-font-smoothing: antialiased;
}

.container {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 24px;
}

/* 顶部声明条 */
.top-declaration-bar {
  background: #fbfbfa;
  border-bottom: 1px solid var(--border-color);
  padding: 8px 0;
  font-size: 12.5px;
}

.dec-content {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.dec-badge {
  background: var(--tag-orange-bg);
  color: var(--tag-orange-text);
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 11.5px;
}

.dec-text {
  color: var(--text-muted);
  flex: 1;
  margin: 0;
}

/* Header */
.site-header {
  background: #ffffff;
  border-bottom: 1px solid var(--border-color);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  font-size: 17px;
  font-weight: 700;
  color: var(--text-main);
}

.notion-page-icon {
  font-size: 20px;
}

.notion-workspace-tag {
  font-size: 13px;
  color: var(--text-dim);
  font-weight: 500;
}

.main-nav {
  display: flex;
  gap: 18px;
}

.nav-link {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 13.5px;
  font-weight: 500;
  transition: var(--transition);
  padding: 6px 8px;
  border-radius: var(--radius-sm);
}

.nav-link:hover, .nav-link.active {
  background: var(--bg-surface);
  color: var(--text-main);
}

.btn-notion-action {
  background: #2383e2;
  color: #ffffff;
  font-weight: 600;
  font-size: 13px;
  padding: 6px 14px;
  border-radius: var(--radius-sm);
  text-decoration: none;
  transition: var(--transition);
}

.btn-notion-action:hover {
  background: #1d70c2;
}

/* Notion 风格 Hero 区域 */
.notion-hero-section {
  padding: 48px 0 36px;
  border-bottom: 1px solid var(--border-color);
}

.notion-cover-header {
  margin-bottom: 24px;
}

.notion-big-icon {
  font-size: 56px;
  margin-bottom: 16px;
  display: inline-block;
}

.hero-breadcrumbs {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--text-dim);
  margin-bottom: 12px;
}

.hero-h1 {
  font-size: 38px;
  font-weight: 800;
  line-height: 1.25;
  color: var(--text-main);
  margin-bottom: 16px;
  letter-spacing: -0.5px;
}

.hero-desc {
  font-size: 16px;
  color: var(--text-muted);
  max-width: 820px;
  margin-bottom: 28px;
  line-height: 1.7;
}

.hero-cta-group {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 30px;
}

.btn-notion-primary {
  background: #2383e2;
  color: #ffffff;
  font-weight: 600;
  font-size: 14.5px;
  padding: 10px 22px;
  border-radius: var(--radius-sm);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: var(--transition);
  box-shadow: var(--shadow-sm);
}

.btn-notion-primary:hover {
  background: #1d70c2;
}

.btn-notion-secondary {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  font-weight: 600;
  font-size: 14.5px;
  padding: 10px 20px;
  border-radius: var(--radius-sm);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: var(--transition);
}

.btn-notion-secondary:hover {
  background: #ebebeb;
}

/* Notion Callout 提示块 */
.notion-callout {
  background: var(--bg-callout);
  border-radius: var(--radius-sm);
  padding: 16px 20px;
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin: 20px 0;
  border: 1px solid var(--border-color);
}

.callout-icon {
  font-size: 22px;
  line-height: 1;
}

.callout-body {
  flex: 1;
  font-size: 14px;
  color: var(--text-main);
}

/* Section 通用 */
.section {
  padding: 44px 0;
}

.section-header {
  margin-bottom: 28px;
}

.section-tag {
  display: inline-block;
  background: var(--tag-blue-bg);
  color: var(--tag-blue-text);
  font-size: 11.5px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  margin-bottom: 8px;
}

.section-title {
  font-size: 24px;
  font-weight: 700;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 8px;
}

.section-subtitle {
  color: var(--text-muted);
  font-size: 14px;
  margin-top: 4px;
}

/* 六宫格/功能模块区 (Notion Gallery Cards) */
.grid-six {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.notion-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 22px;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-sm);
}

.notion-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-active);
  box-shadow: var(--shadow-hover);
  transform: translateY(-2px);
}

.card-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.card-icon {
  font-size: 24px;
}

.card-tag-pill {
  font-size: 11px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: var(--radius-sm);
}

.card-title {
  font-size: 16.5px;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 8px;
}

.card-desc {
  color: var(--text-muted);
  font-size: 13.5px;
  line-height: 1.6;
  margin-bottom: 16px;
  flex: 1;
}

.card-link {
  color: #2383e2;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.card-link:hover {
  text-decoration: underline;
}

/* 正文介绍区：“教程中心”与“我们提供什么” (Notion Toggle-like Panels) */
.intro-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.intro-panel {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 26px;
}

.panel-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.intro-list {
  list-style: none;
}

.intro-list li {
  position: relative;
  padding-left: 20px;
  margin-bottom: 12px;
  color: var(--text-muted);
  font-size: 13.5px;
  line-height: 1.6;
}

.intro-list li::before {
  content: '•';
  position: absolute;
  left: 4px;
  color: var(--text-main);
  font-weight: 900;
  font-size: 16px;
  top: -2px;
}

.intro-list strong {
  color: var(--text-main);
}

/* 热门教程表格 (Notion Database Table Style) */
.table-wrapper {
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.notion-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}

.notion-table th {
  background: var(--bg-surface);
  color: var(--text-muted);
  font-weight: 600;
  font-size: 12.5px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-color);
  border-right: 1px solid var(--border-color);
}

.notion-table th:last-child {
  border-right: none;
}

.notion-table td {
  padding: 14px 16px;
  color: var(--text-muted);
  font-size: 13.5px;
  border-bottom: 1px solid var(--border-color);
  border-right: 1px solid var(--border-color);
}

.notion-table td:last-child {
  border-right: none;
}

.notion-table tr:last-child td {
  border-bottom: none;
}

.notion-table tr:hover td {
  background: #fafaf9;
  color: var(--text-main);
}

.badge-tag {
  display: inline-block;
  padding: 2px 7px;
  border-radius: var(--radius-sm);
  font-size: 11.5px;
  font-weight: 600;
}

.badge-easy {
  background: var(--tag-green-bg);
  color: var(--tag-green-text);
}

.badge-medium {
  background: var(--tag-yellow-bg);
  color: var(--tag-yellow-text);
}

.badge-hard {
  background: var(--tag-pink-bg);
  color: var(--tag-pink-text);
}

.tbl-link {
  color: #2383e2;
  text-decoration: none;
  font-weight: 600;
  font-size: 13px;
}

.tbl-link:hover {
  text-decoration: underline;
}

/* FAQ 常见问答模块 */
.faq-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.faq-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 20px;
  transition: var(--transition);
  box-shadow: var(--shadow-sm);
}

.faq-card:hover {
  border-color: var(--border-active);
  background: var(--bg-card-hover);
}

.faq-q {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 8px;
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.faq-q-icon {
  color: #2383e2;
}

.faq-a {
  color: var(--text-muted);
  font-size: 13.5px;
  line-height: 1.6;
}

/* 延伸阅读与免责入口卡片 */
.extended-reading {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 24px 28px;
  margin-top: 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 18px;
}

.reading-info h4 {
  font-size: 16.5px;
  color: var(--text-main);
  margin-bottom: 4px;
  font-weight: 700;
}

.reading-info p {
  color: var(--text-muted);
  font-size: 13.5px;
}

.reading-actions {
  display: flex;
  gap: 10px;
}

/* 子页面通用文章样式 (Notion Document View) */
.page-hero {
  padding: 40px 0 24px;
  border-bottom: 1px solid var(--border-color);
  background: #ffffff;
}

.page-title {
  font-size: 30px;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 8px;
  letter-spacing: -0.4px;
}

.page-subtitle {
  color: var(--text-muted);
  font-size: 14.5px;
  max-width: 800px;
}

.content-section {
  padding: 36px 0;
}

.article-content {
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 36px;
  color: #403e39;
  line-height: 1.8;
  box-shadow: var(--shadow-sm);
}

.article-content h2 {
  font-size: 20px;
  color: var(--text-main);
  margin: 28px 0 12px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  gap: 6px;
}

.article-content h3 {
  font-size: 16px;
  color: #2383e2;
  margin: 18px 0 8px;
}

.article-content p {
  margin-bottom: 14px;
  font-size: 14.5px;
}

.article-content ul, .article-content ol {
  margin-bottom: 16px;
  padding-left: 22px;
}

.article-content li {
  margin-bottom: 6px;
}

.article-content strong {
  color: var(--text-main);
}

.tool-callout {
  background: var(--bg-callout);
  border-left: 3px solid #2383e2;
  padding: 14px 18px;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  margin: 20px 0;
  color: var(--text-main);
  font-size: 14px;
}

.code-box {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 16px;
  font-family: var(--font-mono);
  font-size: 13px;
  color: #1a1a1a;
  overflow-x: auto;
  margin: 18px 0;
}

/* 页脚 */
.site-footer {
  background: var(--bg-surface);
  border-top: 1px solid var(--border-color);
  padding: 44px 0 28px;
  margin-top: 44px;
}

.footer-inner {
  display: grid;
  grid-template-columns: 1.5fr 2fr;
  gap: 40px;
  margin-bottom: 28px;
}

.footer-desc {
  color: var(--text-muted);
  font-size: 13px;
  margin: 12px 0;
  line-height: 1.6;
  max-width: 400px;
}

.copyright {
  color: var(--text-dim);
  font-size: 12px;
}

.footer-links {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.link-col h4 {
  color: var(--text-main);
  font-size: 13.5px;
  margin-bottom: 12px;
  font-weight: 700;
}

.link-col a {
  display: block;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 13px;
  margin-bottom: 8px;
  transition: var(--transition);
}

.link-col a:hover {
  color: #2383e2;
}

/* 响应式断点 */
@media (max-width: 992px) {
  .grid-six {
    grid-template-columns: repeat(2, 1fr);
  }
  .intro-container {
    grid-template-columns: 1fr;
  }
  .faq-grid {
    grid-template-columns: 1fr;
  }
  .footer-inner {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .main-nav {
    display: none;
  }
  .hero-h1 {
    font-size: 26px;
  }
  .grid-six {
    grid-template-columns: 1fr;
  }
  .footer-links {
    grid-template-columns: 1fr 1fr;
  }
}