:root {
  --peach: #e85d4a;
  --peach-light: #fff3ef;
  --peach-dark: #c94a38;
  --text: #2c2c2c;
  --text-soft: #666;
  --card: #ffffff;
  --radius: 16px;
  --shadow: 0 4px 20px rgba(232, 93, 74, 0.12);
}

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

html {
  font-size: 20px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB",
    "Microsoft YaHei", "Helvetica Neue", sans-serif;
  background: linear-gradient(180deg, var(--peach-light) 0%, #fff 240px);
  color: var(--text);
  line-height: 1.75;
  min-height: 100vh;
  padding-bottom: 88px;
}

a { color: var(--peach); text-decoration: none; }

/* 顶部 */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(232, 93, 74, 0.15);
  padding: 14px 18px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.site-logo {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, #ffb199, var(--peach));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  flex-shrink: 0;
}

.site-title h1 {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--peach-dark);
  line-height: 1.3;
}

.site-title p {
  font-size: 0.75rem;
  color: var(--text-soft);
}

/* 容器 */
.container {
  max-width: 640px;
  margin: 0 auto;
  padding: 18px 16px 24px;
}

/* 首页横幅 */
.hero {
  background: linear-gradient(135deg, var(--peach) 0%, #ff8f7a 100%);
  color: #fff;
  border-radius: var(--radius);
  padding: 24px 20px;
  margin-bottom: 20px;
  box-shadow: var(--shadow);
}

.hero h2 {
  font-size: 1.35rem;
  margin-bottom: 10px;
  line-height: 1.4;
}

.hero p {
  font-size: 0.9rem;
  opacity: 0.95;
  line-height: 1.6;
}

.hero .badge {
  display: inline-block;
  background: rgba(255,255,255,0.25);
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.75rem;
  margin-top: 12px;
}

/* 文章卡片 */
.article-list { display: flex; flex-direction: column; gap: 14px; }

.article-card {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--card);
  border-radius: var(--radius);
  padding: 18px 16px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(232, 93, 74, 0.08);
  transition: transform 0.15s;
}

.article-card:active { transform: scale(0.98); }

.article-num {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--peach-light);
  color: var(--peach);
  font-size: 1.2rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.article-card h3 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  line-height: 1.45;
  margin-bottom: 4px;
}

.article-card .desc {
  font-size: 0.8rem;
  color: var(--text-soft);
}

.article-card .arrow {
  margin-left: auto;
  color: var(--peach);
  font-size: 1.2rem;
  flex-shrink: 0;
}

/* 文章正文 */
.article-meta {
  background: var(--card);
  border-radius: var(--radius);
  padding: 16px 18px;
  margin-bottom: 16px;
  border-left: 4px solid var(--peach);
  font-size: 0.85rem;
  color: var(--text-soft);
  line-height: 1.6;
}

.article-body {
  background: var(--card);
  border-radius: var(--radius);
  padding: 22px 18px;
  box-shadow: var(--shadow);
}

.article-body h1 {
  font-size: 1.4rem;
  color: var(--peach-dark);
  margin-bottom: 18px;
  line-height: 1.4;
}

.article-body h2 {
  font-size: 1.15rem;
  color: var(--peach-dark);
  margin: 28px 0 12px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--peach-light);
}

.article-body h2:first-of-type { margin-top: 0; }

.article-body p {
  margin-bottom: 14px;
  font-size: 1rem;
}

.article-body blockquote {
  background: var(--peach-light);
  border-left: 4px solid var(--peach);
  padding: 14px 16px;
  margin: 16px 0;
  border-radius: 0 12px 12px 0;
  font-size: 0.95rem;
  color: #444;
}

.article-body blockquote p { margin-bottom: 8px; }
.article-body blockquote p:last-child { margin-bottom: 0; }

.article-body ul, .article-body ol {
  margin: 12px 0 16px 22px;
}

.article-body li {
  margin-bottom: 8px;
  font-size: 1rem;
}

.article-body table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0;
  font-size: 0.9rem;
  display: block;
  overflow-x: auto;
}

.article-body th, .article-body td {
  border: 1px solid #f0d5cf;
  padding: 10px 12px;
  text-align: left;
  min-width: 100px;
}

.article-body th {
  background: var(--peach-light);
  color: var(--peach-dark);
  font-weight: 600;
}

.article-body hr {
  border: none;
  border-top: 1px dashed #f0d5cf;
  margin: 24px 0;
}

.article-body strong { color: var(--peach-dark); }

.article-body .footer-note {
  margin-top: 24px;
  padding-top: 16px;
  border-top: 1px solid #f0f0f0;
  font-size: 0.85rem;
  color: var(--text-soft);
  text-align: center;
}

/* 底部导航 */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(255,255,255,0.98);
  border-top: 1px solid rgba(232, 93, 74, 0.12);
  display: flex;
  justify-content: space-around;
  padding: 10px 8px calc(10px + env(safe-area-inset-bottom));
  z-index: 100;
}

.bottom-nav a {
  flex: 1;
  text-align: center;
  padding: 8px 4px;
  font-size: 0.8rem;
  color: var(--text-soft);
}

.bottom-nav a.active { color: var(--peach); font-weight: 600; }
.bottom-nav .icon { display: block; font-size: 1.3rem; margin-bottom: 2px; }

/* 文章翻页 */
.pager {
  display: flex;
  gap: 12px;
  margin-top: 20px;
}

.pager a {
  flex: 1;
  background: var(--card);
  border-radius: 12px;
  padding: 14px 12px;
  text-align: center;
  font-size: 0.85rem;
  box-shadow: var(--shadow);
  border: 1px solid rgba(232, 93, 74, 0.08);
}

.pager a.disabled {
  opacity: 0.4;
  pointer-events: none;
}

/* 二维码页 */
.qr-page { text-align: center; }

.qr-box {
  background: var(--card);
  border-radius: var(--radius);
  padding: 28px 20px;
  box-shadow: var(--shadow);
  margin-bottom: 16px;
}

.qr-box img {
  width: 220px;
  height: 220px;
  border: 8px solid var(--peach-light);
  border-radius: 12px;
}

.qr-url {
  word-break: break-all;
  font-size: 0.85rem;
  color: var(--peach);
  margin-top: 16px;
  padding: 12px;
  background: var(--peach-light);
  border-radius: 8px;
}

.qr-steps {
  text-align: left;
  background: var(--card);
  border-radius: var(--radius);
  padding: 20px 18px;
  box-shadow: var(--shadow);
}

.qr-steps h3 {
  font-size: 1rem;
  color: var(--peach-dark);
  margin-bottom: 12px;
}

.qr-steps li {
  margin-bottom: 10px;
  font-size: 0.9rem;
  line-height: 1.6;
}

.tip-box {
  background: #fffbe6;
  border: 1px solid #ffe58f;
  border-radius: 12px;
  padding: 14px 16px;
  font-size: 0.85rem;
  color: #8c6d1f;
  margin-top: 16px;
  text-align: left;
}
