/* ==========================================================================
   作品集子站 · 设计系统
   极简浅色 / 大留白 / 细边框卡片 / 克制动效
   ========================================================================== */

:root {
  --bg: #fcfcfd;
  --bg-alt: #f6f7f9;
  --surface: #ffffff;

  --text: #0f1115;
  --text-2: #565b66;
  --text-3: #8b909b;

  --line: #e6e8ec;
  --line-strong: #d4d8e0;

  --brand: #4f5bd5;
  --brand-soft: #eef0fe;
  --brand-dark: #3f49b8;

  --radius: 18px;
  --radius-sm: 12px;
  --shadow-sm: 0 1px 2px rgba(16, 18, 24, .04);
  --shadow-md: 0 18px 40px -22px rgba(16, 18, 24, .25);

  --maxw: 1120px;
  --nav-h: 64px;

  --font: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI",
    "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

::selection { background: rgba(79, 91, 213, .16); }

.wrap {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- 顶部导航 ---------- */

.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 60;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  background: rgba(252, 252, 253, .72);
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  border-bottom: 1px solid transparent;
  transition: border-color .3s ease, background .3s ease;
}

.nav.is-scrolled {
  background: rgba(252, 252, 253, .92);
  border-bottom-color: var(--line);
}

.nav .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 620;
  font-size: 15px;
  letter-spacing: -.01em;
  white-space: nowrap;
}

.brand-mark {
  width: 26px; height: 26px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: linear-gradient(140deg, var(--brand), #7c8cf8);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  box-shadow: 0 4px 10px -4px rgba(79, 91, 213, .6);
}

.brand-sub {
  color: var(--text-3);
  font-weight: 450;
  font-size: 13px;
  letter-spacing: .01em;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}

.nav-link {
  position: relative;
  padding: 7px 13px;
  border-radius: 999px;
  font-size: 14px;
  color: var(--text-2);
  transition: color .2s ease, background .2s ease;
}

.nav-link:hover { color: var(--text); background: var(--bg-alt); }

.nav-link.is-active {
  color: var(--brand);
  background: var(--brand-soft);
  font-weight: 560;
}

.nav-ext {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-left: 8px;
  padding: 7px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  font-size: 13.5px;
  color: var(--text-2);
  background: var(--surface);
  transition: .2s ease;
}

.nav-ext:hover {
  border-color: var(--line-strong);
  color: var(--text);
  box-shadow: var(--shadow-sm);
}

.nav-ext svg { width: 15px; height: 15px; }

/* ---------- 通用区块 ---------- */

.section { padding: 88px 0; }
.section-tight { padding: 56px 0; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 12px 5px 10px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface);
  font-size: 12.5px;
  font-weight: 520;
  letter-spacing: .04em;
  color: var(--text-2);
  text-transform: uppercase;
}

.eyebrow::before {
  content: "";
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--brand);
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 36px;
}

.section-title {
  margin: 14px 0 0;
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 650;
  letter-spacing: -.025em;
  line-height: 1.3;
}

.section-desc {
  margin: 10px 0 0;
  color: var(--text-2);
  font-size: 15px;
  max-width: 56ch;
}

.link-more {
  flex-shrink: 0;
  font-size: 14px;
  color: var(--text-2);
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding-bottom: 2px;
  border-bottom: 1px solid var(--line-strong);
  transition: .2s ease;
}

.link-more:hover { color: var(--brand); border-bottom-color: var(--brand); }

/* ---------- Hero（首页） ---------- */

.hero {
  position: relative;
  padding: calc(var(--nav-h) + 92px) 0 76px;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: -280px -10% auto -10%;
  height: 780px;
  background:
    radial-gradient(46% 52% at 50% 34%, rgba(79, 91, 213, .12), transparent 72%),
    radial-gradient(34% 40% at 82% 12%, rgba(45, 212, 191, .13), transparent 70%),
    radial-gradient(30% 36% at 14% 22%, rgba(244, 114, 182, .09), transparent 70%);
  pointer-events: none;
}

.hero .wrap { position: relative; }

.hero h1 {
  margin: 22px 0 0;
  font-size: clamp(38px, 6.4vw, 68px);
  line-height: 1.12;
  font-weight: 680;
  letter-spacing: -.04em;
  max-width: 16ch;
}

.hero h1 em {
  font-style: normal;
  background: linear-gradient(96deg, var(--brand), #7c8cf8 55%, #38bdf8);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-lead {
  margin: 24px 0 0;
  font-size: clamp(15.5px, 1.6vw, 18px);
  line-height: 1.8;
  color: var(--text-2);
  max-width: 54ch;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 34px;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 20px;
  border-radius: 999px;
  font-size: 14.5px;
  font-weight: 540;
  border: 1px solid transparent;
  transition: .22s cubic-bezier(.2, .8, .2, 1);
  cursor: pointer;
}

.btn-primary {
  background: var(--text);
  color: #fff;
  box-shadow: 0 10px 24px -14px rgba(15, 17, 21, .8);
}

.btn-primary:hover { transform: translateY(-1px); background: #000; }

.btn-ghost {
  background: var(--surface);
  border-color: var(--line);
  color: var(--text-2);
}

.btn-ghost:hover {
  border-color: var(--line-strong);
  color: var(--text);
  transform: translateY(-1px);
}

.btn svg { width: 16px; height: 16px; }

.hero-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 44px;
  margin-top: 64px;
  padding-top: 32px;
  border-top: 1px solid var(--line);
}

.stat-num {
  font-size: 26px;
  font-weight: 660;
  letter-spacing: -.03em;
  line-height: 1.2;
}

.stat-label {
  font-size: 13px;
  color: var(--text-3);
  margin-top: 2px;
}

/* ---------- 分类入口卡 ---------- */

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

.cat-card {
  position: relative;
  display: block;
  padding: 28px 26px 24px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--surface);
  transition: .3s cubic-bezier(.2, .8, .2, 1);
  overflow: hidden;
}

.cat-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(120% 90% at 100% 0%, var(--tint, rgba(79, 91, 213, .09)), transparent 62%);
  opacity: 0;
  transition: opacity .3s ease;
}

.cat-card:hover {
  transform: translateY(-4px);
  border-color: var(--line-strong);
  box-shadow: var(--shadow-md);
}

.cat-card:hover::after { opacity: 1; }

.cat-icon {
  position: relative;
  width: 42px; height: 42px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: var(--bg-alt);
  border: 1px solid var(--line);
  color: var(--brand);
}

.cat-icon svg { width: 21px; height: 21px; }

.cat-name {
  position: relative;
  margin: 20px 0 0;
  font-size: 18.5px;
  font-weight: 620;
  letter-spacing: -.02em;
}

.cat-desc {
  position: relative;
  margin: 8px 0 0;
  font-size: 14px;
  color: var(--text-2);
  line-height: 1.7;
  min-height: 3.4em;
}

.cat-meta {
  position: relative;
  margin-top: 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13px;
  color: var(--text-3);
}

.cat-arrow {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--text-2);
  transition: transform .3s ease, color .3s ease;
}

.cat-card:hover .cat-arrow { transform: translateX(3px); color: var(--brand); }

/* ---------- 项目卡片 ---------- */

.proj-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(316px, 1fr));
  gap: 22px;
}

/* 首页精选：固定两列，卡片放大后版面更平衡 */
.proj-grid[data-featured="true"] {
  grid-template-columns: repeat(2, 1fr);
}

.proj-grid[data-featured="true"] .proj-cover { aspect-ratio: 21 / 9; }
.proj-grid[data-featured="true"] .proj-body { padding: 24px 26px 26px; }
.proj-grid[data-featured="true"] .proj-title { font-size: 19px; }
.proj-grid[data-featured="true"] .proj-desc { font-size: 14.5px; }

/* 列表卡片入场：只做位移，不动 opacity ——
   动画即便未执行，内容也始终可见，不依赖任何 JS 时序 */
@keyframes cardIn {
  from { translate: 0 14px; }
  to   { translate: 0 0; }
}

.proj-card {
  position: relative;
  display: flex;
  flex-direction: column;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--surface);
  overflow: hidden;
  transition: .3s cubic-bezier(.2, .8, .2, 1);
  animation: cardIn .56s cubic-bezier(.2, .8, .2, 1) both;
}

.proj-grid .proj-card:nth-child(1) { animation-delay: .02s; }
.proj-grid .proj-card:nth-child(2) { animation-delay: .08s; }
.proj-grid .proj-card:nth-child(3) { animation-delay: .14s; }
.proj-grid .proj-card:nth-child(4) { animation-delay: .2s; }
.proj-grid .proj-card:nth-child(5) { animation-delay: .26s; }
.proj-grid .proj-card:nth-child(n+6) { animation-delay: .3s; }

.proj-card:hover {
  transform: translateY(-4px);
  border-color: var(--line-strong);
  box-shadow: var(--shadow-md);
}

.proj-cover {
  position: relative;
  aspect-ratio: 16 / 9;
  background: linear-gradient(135deg, #4f5bd5, #7c8cf8);
  display: grid;
  place-items: center;
  overflow: hidden;
}

.proj-cover::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(circle at 22% 78%, rgba(255, 255, 255, .22), transparent 42%),
    radial-gradient(circle at 82% 18%, rgba(255, 255, 255, .16), transparent 46%);
}

.proj-cover span {
  position: relative;
  z-index: 1;
  color: rgba(255, 255, 255, .95);
  font-size: 30px;
  font-weight: 680;
  letter-spacing: .1em;
  text-indent: .1em;
}

.proj-cover img {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
}

.proj-body {
  padding: 20px 22px 22px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.proj-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.proj-title {
  margin: 0;
  font-size: 17px;
  font-weight: 620;
  letter-spacing: -.02em;
}

.proj-desc {
  margin: 9px 0 0;
  font-size: 13.8px;
  color: var(--text-2);
  line-height: 1.72;
  flex: 1;
}

.proj-foot {
  margin-top: 18px;
  padding-top: 15px;
  border-top: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tag {
  font-size: 11.5px;
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--bg-alt);
  color: var(--text-3);
  border: 1px solid var(--line);
  white-space: nowrap;
}

.proj-year {
  font-size: 12.5px;
  color: var(--text-3);
  font-family: var(--mono);
  flex-shrink: 0;
}

/* 状态徽章 */

.badge {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 540;
  border: 1px solid;
  white-space: nowrap;
}

.badge::before {
  content: "";
  width: 5px; height: 5px;
  border-radius: 50%;
  background: currentColor;
}

.badge-live { color: #0f8a5f; background: #eefbf5; border-color: #c6eedd; }
.badge-dev { color: #b45309; background: #fff8ed; border-color: #f8e0bd; }
.badge-oss { color: var(--brand); background: var(--brand-soft); border-color: #d8ddfb; }
.badge-archive { color: var(--text-3); background: var(--bg-alt); border-color: var(--line); }

/* ---------- 空状态 / 占位 ---------- */

.placeholder {
  padding: 64px 32px;
  border-radius: var(--radius);
  border: 1px dashed var(--line-strong);
  background: linear-gradient(180deg, var(--surface), var(--bg-alt));
  text-align: center;
  animation: cardIn .5s cubic-bezier(.2, .8, .2, 1) both;
}

.placeholder-icon {
  width: 48px; height: 48px;
  margin: 0 auto 18px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: var(--surface);
  border: 1px solid var(--line);
  color: var(--text-3);
}

.placeholder-icon svg { width: 22px; height: 22px; }

.placeholder h3 {
  margin: 0;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -.02em;
}

.placeholder p {
  margin: 9px auto 0;
  font-size: 14px;
  color: var(--text-2);
  max-width: 44ch;
  line-height: 1.75;
}

/* ---------- 计划收录（空分类用） ---------- */

.plan-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin-top: 20px;
}

.plan-item {
  display: flex;
  gap: 13px;
  align-items: flex-start;
  padding: 19px 21px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: var(--surface);
}

.plan-idx {
  font-family: var(--mono);
  font-size: 11.5px;
  line-height: 1.9;
  color: var(--text-3);
  flex-shrink: 0;
}

.plan-item h4 {
  margin: 0;
  font-size: 14.5px;
  font-weight: 600;
  letter-spacing: -.01em;
}

.plan-item p {
  margin: 5px 0 0;
  font-size: 13.5px;
  color: var(--text-2);
  line-height: 1.72;
}

.plan-title {
  margin: 48px 0 0;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--text-3);
}

/* ---------- 分类页头 ---------- */

.page-head {
  position: relative;
  padding: calc(var(--nav-h) + 62px) 0 46px;
  overflow: hidden;
}

.page-head::before {
  content: "";
  position: absolute;
  inset: -220px -10% auto -10%;
  height: 560px;
  background: radial-gradient(42% 50% at 22% 40%, var(--tint, rgba(79, 91, 213, .1)), transparent 70%);
  pointer-events: none;
}

.page-head .wrap { position: relative; }

.page-head h1 {
  margin: 16px 0 0;
  font-size: clamp(30px, 4.4vw, 44px);
  font-weight: 680;
  letter-spacing: -.035em;
  line-height: 1.2;
}

.page-head p {
  margin: 16px 0 0;
  font-size: 15.5px;
  color: var(--text-2);
  max-width: 58ch;
  line-height: 1.8;
}

.count-line {
  margin-top: 26px;
  font-size: 13px;
  color: var(--text-3);
  font-family: var(--mono);
}

/* ---------- 详情页 ---------- */

.detail-head {
  position: relative;
  padding: calc(var(--nav-h) + 44px) 0 0;
  overflow: hidden;
}

.detail-head::before {
  content: "";
  position: absolute;
  inset: -240px -10% auto -10%;
  height: 600px;
  background: radial-gradient(44% 54% at 30% 42%, var(--tint, rgba(79, 91, 213, .11)), transparent 70%);
  pointer-events: none;
}

.detail-head .wrap { position: relative; }

.crumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--text-3);
  margin-bottom: 26px;
}

.crumb a:hover { color: var(--text); }
.crumb span.sep { color: var(--line-strong); }

.detail-title {
  margin: 18px 0 0;
  font-size: clamp(32px, 5vw, 52px);
  font-weight: 680;
  letter-spacing: -.04em;
  line-height: 1.14;
}

.detail-sub {
  margin: 18px 0 0;
  font-size: clamp(15.5px, 1.7vw, 18px);
  color: var(--text-2);
  line-height: 1.78;
  max-width: 56ch;
}

.detail-meta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-top: 26px;
}

.detail-cover {
  margin-top: 44px;
  aspect-ratio: 2.7 / 1;
  border-radius: 20px;
  border: 1px solid var(--line);
  background: linear-gradient(135deg, #4f5bd5, #7c8cf8);
  display: grid;
  place-items: center;
  overflow: hidden;
  position: relative;
}

.detail-cover::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(circle at 18% 82%, rgba(255, 255, 255, .2), transparent 44%),
    radial-gradient(circle at 86% 16%, rgba(255, 255, 255, .14), transparent 46%);
}

/* 封面网格纹理，避免纯色块显得空 */
.detail-cover::after,
.proj-cover::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    repeating-linear-gradient(0deg, rgba(255, 255, 255, .13) 0 1px, transparent 1px 38px),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, .13) 0 1px, transparent 1px 38px);
  -webkit-mask-image: radial-gradient(circle at 50% 50%, #000 24%, transparent 88%);
  mask-image: radial-gradient(circle at 50% 50%, #000 24%, transparent 88%);
}

.detail-cover span {
  position: relative;
  z-index: 1;
  color: rgba(255, 255, 255, .95);
  font-size: clamp(28px, 5vw, 46px);
  font-weight: 680;
  letter-spacing: -.03em;
}

.detail-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 268px;
  gap: 64px;
  padding: 64px 0 0;
  align-items: start;
}

.prose {
  max-width: 690px;
}

.prose h2 {
  margin: 52px 0 0;
  font-size: 21px;
  font-weight: 640;
  letter-spacing: -.025em;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}

.prose code {
  font-family: var(--mono);
  font-size: .86em;
  padding: 2px 6px;
  border-radius: 5px;
  background: var(--bg-alt);
  border: 1px solid var(--line);
  color: var(--text);
  white-space: nowrap;
}

.prose h2:first-child { margin-top: 0; }

.prose p {
  margin: 16px 0 0;
  font-size: 15.5px;
  line-height: 1.9;
  color: var(--text-2);
}

.prose ul {
  margin: 16px 0 0;
  padding: 0;
  list-style: none;
}

.prose ul li {
  position: relative;
  padding-left: 22px;
  margin-top: 11px;
  font-size: 15px;
  line-height: 1.8;
  color: var(--text-2);
}

.prose ul li::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 11px;
  width: 6px; height: 6px;
  border-radius: 50%;
  border: 1.5px solid var(--brand);
}

.prose ul li strong { color: var(--text); font-weight: 600; }

.spec-table {
  width: 100%;
  margin-top: 16px;
  border-collapse: collapse;
  font-size: 14px;
}

.spec-table tr { border-bottom: 1px solid var(--line); }
.spec-table tr:last-child { border-bottom: none; }

.spec-table th {
  text-align: left;
  padding: 11px 16px 11px 0;
  color: var(--text-3);
  font-weight: 450;
  white-space: nowrap;
  width: 96px;
  vertical-align: top;
}

.spec-table td {
  padding: 11px 0;
  color: var(--text);
  line-height: 1.7;
}

/* 侧栏 */

.detail-side {
  position: sticky;
  top: calc(var(--nav-h) + 24px);
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.side-card {
  padding: 20px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: var(--surface);
}

.side-card h4 {
  margin: 0 0 14px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: var(--text-3);
}

.side-links { display: flex; flex-direction: column; gap: 2px; }

.side-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 9px 10px;
  margin: 0 -10px;
  border-radius: 8px;
  font-size: 14px;
  color: var(--text-2);
  transition: .18s ease;
}

.side-link:hover { background: var(--bg-alt); color: var(--brand); }
.side-link svg { width: 14px; height: 14px; opacity: .5; flex-shrink: 0; }

.side-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

/* ---------- 上/下一个 ---------- */

.pager {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
  margin-top: 72px;
  padding-top: 40px;
  border-top: 1px solid var(--line);
}

.pager-item {
  padding: 20px 22px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: var(--surface);
  transition: .25s ease;
}

.pager-item:hover {
  border-color: var(--line-strong);
  box-shadow: var(--shadow-sm);
  transform: translateY(-2px);
}

.pager-item .dir {
  font-size: 12px;
  color: var(--text-3);
  letter-spacing: .04em;
}

.pager-item .name {
  margin-top: 6px;
  font-size: 15.5px;
  font-weight: 580;
  letter-spacing: -.01em;
}

.pager-item.next { text-align: right; }
.pager-item.is-empty { visibility: hidden; }

/* ---------- Footer ---------- */

.footer {
  margin-top: 96px;
  padding: 44px 0 52px;
  border-top: 1px solid var(--line);
  background: var(--bg-alt);
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  font-size: 13.5px;
  color: var(--text-3);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

.footer-links a { transition: color .2s ease; }
.footer-links a:hover { color: var(--text); }

/* ---------- 动效 ---------- */

.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition:
    opacity .72s cubic-bezier(.2, .8, .2, 1),
    transform .72s cubic-bezier(.2, .8, .2, 1);
}

.reveal.in {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .proj-card, .placeholder { animation: none; opacity: 1; translate: 0 0; }
  .proj-card:hover, .cat-card:hover, .pager-item:hover, .btn:hover { transform: none; }
}

/* ---------- 响应式 ---------- */

@media (max-width: 900px) {
  .detail-body {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .detail-side { position: static; }
  .cat-grid { grid-template-columns: 1fr; gap: 14px; }
  .cat-desc { min-height: 0; }
  .plan-grid { grid-template-columns: 1fr; }
  .pager { grid-template-columns: 1fr; }
  .pager-item.next { text-align: left; }
}

@media (max-width: 720px) {
  :root { --nav-h: 58px; }

  .wrap { padding: 0 18px; }

  .section { padding: 62px 0; }
  .hero { padding: calc(var(--nav-h) + 62px) 0 52px; }
  .hero-stats { gap: 28px; margin-top: 46px; }
  .stat-num { font-size: 22px; }

  .brand-sub { display: none; }
  .nav-link { padding: 6px 10px; font-size: 13px; }
  .nav-ext { padding: 6px 10px; margin-left: 2px; }
  .nav-ext span { display: none; }

  .proj-grid { grid-template-columns: 1fr; }
  .proj-grid[data-featured="true"] { grid-template-columns: 1fr; }
  .proj-grid[data-featured="true"] .proj-cover { aspect-ratio: 16 / 9; }
  .section-head { flex-direction: column; align-items: flex-start; gap: 12px; }
  .detail-cover { aspect-ratio: 16 / 10; margin-top: 30px; }
  .footer { margin-top: 64px; }
}
