/* ============================================================
   详情页公共样式（mini-program / app 共用）
   ============================================================ */
:root {
  /* —— 9 色完整色板（与主站 styles.css 同步）—— */
  --bg: #f2f4f8;            /* 主背景 */
  --paper: #f7f4ed;         /* 纸色：宣纸模拟 */
  --text: #1e252b;          /* 深墨 */
  --text-light: #4a5563;    /* 中墨 */
  --text-lighter: #8895a0;  /* 淡墨 */
  --border: #dce1e6;
  --border-light: #e5e9ef;
  --red-deep: #8b1a1a;      /* 梅红深 */
  --red: #b83b3b;           /* 梅红中 */
  --red-light: #d45c5c;     /* 梅红浅 */
  --red-pale: #e88484;      /* 梅红淡 */
  --gold: #c8a45c;          /* 暖金 */
  --white: #fff;
  --frosted: rgba(255, 255, 255, 0.6);

  /* —— 三档字体系统 —— */
  --serif: 'Noto Serif SC', 'SimSun', 'STSong', serif;
  --sans: 'PingFang SC', 'Microsoft YaHei', system-ui, -apple-system, sans-serif;
  --kai: 'LXGW WenKai', 'STKaiti', 'KaiTi', serif;
  --mono: 'JetBrains Mono', 'Consolas', monospace;

  /* —— 字号梯度 —— */
  --fs-h1: 2.5rem;
  --fs-h2: 1.75rem;
  --fs-h3: 1.25rem;
  --fs-body: 1rem;
  --fs-small: 0.875rem;
  --fs-caption: 0.75rem;
}

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

/* 无障碍：跳到主内容 + 键盘焦点样式 */
.skip-link {
  position: fixed; top: -100px; left: 16px; z-index: 2000;
  padding: 10px 20px; background: var(--red); color: var(--white);
  border-radius: 4px; font-size: 0.9rem; text-decoration: none;
  transition: top 0.3s ease;
}
.skip-link:focus { top: 16px; }
a:focus-visible, button:focus-visible {
  outline: 2px solid var(--red-light); outline-offset: 3px; border-radius: 2px;
}

html { scroll-behavior: smooth; }
body {
  font-family: var(--sans);
  background-color: var(--bg);
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='240' height='240'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0.12  0 0 0 0 0.10  0 0 0 0 0.08  0 0 0 0.45 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  background-size: 240px 240px;
  background-repeat: repeat;
  color: var(--text);
  line-height: 1.75;
  letter-spacing: 0.2px;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

#particleCanvas {
  position: fixed; top: 0; left: 0; width: 100%; height: 100%;
  z-index: 0; pointer-events: none;
}
.navbar, .detail-section, .footer { position: relative; z-index: 1; }
.decorative-line {
  display: block; width: 40px; height: 2px;
  background: var(--red-light); margin: 12px auto 0; border-radius: 1px;
}

.navbar {
  position: fixed; top: 0; left: 0; width: 100%; z-index: 1000;
  padding: 16px 24px;
  display: flex; align-items: center; justify-content: space-between;
  background: var(--frosted);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 1px 10px rgba(0, 0, 0, 0.04);
}
.nav-back {
  font-family: var(--sans); font-size: 0.95rem;
  color: var(--text-light); text-decoration: none; transition: color 0.3s;
}
.nav-back:hover { color: var(--red); }
.nav-logo {
  font-family: var(--serif); font-size: 1.25rem; font-weight: 700;
  color: var(--text); text-decoration: none; letter-spacing: 3px;
}

.detail-section { min-height: 100vh; padding: 120px 24px 80px; }
.container { max-width: 800px; margin: 0 auto; }
.detail-title {
  font-family: var(--serif); font-size: var(--fs-h1); font-weight: 700;
  text-align: center; color: var(--text); margin-bottom: 8px; letter-spacing: 2px;
}
.detail-subtitle {
  text-align: center; color: var(--text-light); font-size: var(--fs-small);
  margin-bottom: 16px; font-family: var(--kai); letter-spacing: 1px;
}
.detail-tag {
  text-align: center; margin-bottom: 48px;
}
.detail-tag span {
  display: inline-block; padding: 4px 14px;
  border: 1px solid var(--border); border-radius: 16px;
  font-size: 0.8rem; color: var(--text-lighter); margin: 0 4px;
}

.detail-content {
  background: var(--paper);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border: 1px solid var(--border); border-radius: 10px;
  padding: 36px; margin-bottom: 28px;
}
.detail-content h3 {
  font-family: var(--serif); font-size: 1.15rem; font-weight: 600;
  color: var(--text); margin-bottom: 14px; margin-top: 24px;
}
.detail-content h3:first-child { margin-top: 0; }
.detail-content p {
  color: var(--text-light); font-size: 0.92rem; margin-bottom: 12px;
}
.detail-content ul {
  list-style: none; padding-left: 0; margin-bottom: 12px;
}
.detail-content ul li {
  color: var(--text-light); font-size: 0.9rem;
  padding-left: 18px; position: relative; margin-bottom: 6px;
}
.detail-content ul li::before {
  content: '·'; position: absolute; left: 6px; top: 0;
  color: var(--red-light); font-weight: 700;
}
.tech-stack {
  display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px;
}
.tech-stack span {
  padding: 4px 12px; border: 1px solid #c0c8d2; border-radius: 14px;
  font-size: 0.8rem; color: var(--text-light); background: transparent;
}

.status-note {
  background: rgba(139, 26, 26, 0.05);
  border-left: 3px solid var(--red-deep);
  border-radius: 0 6px 6px 0;
  padding: 14px 20px; margin-bottom: 28px;
  color: var(--text-light); font-size: 0.88rem;
}

.image-gallery {
  display: grid; grid-template-columns: repeat(2, 1fr);
  gap: 16px; margin-bottom: 40px;
}
.image-gallery img {
  width: 100%; height: auto; border-radius: 8px;
  border: 1px solid var(--border);
  transition: transform 0.3s, box-shadow 0.3s;
  display: block;
}
.image-gallery img:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(139, 26, 26, 0.12);
}

.btn-back {
  display: block; width: fit-content; margin: 0 auto;
  padding: 10px 28px;
  border: 1px solid var(--red-deep); border-radius: 4px;
  color: var(--red-deep); text-decoration: none; font-size: 0.9rem;
  transition: background 0.3s, color 0.3s;
}
.btn-back:hover { background: var(--red-deep); color: var(--white); }

.footer {
  text-align: center; padding: 36px 24px;
  color: var(--text-lighter); font-size: 0.85rem;
  border-top: 1px solid var(--border-light);
}

@media (max-width: 768px) {
  .detail-section { padding: 100px 20px 60px; }
  .detail-title { font-size: 1.6rem; }
  .detail-content { padding: 24px; }
  .image-gallery { grid-template-columns: 1fr; }
}
