/* ============================================================
   林志荣 · 个人主页
   Fluent / WinUI 风格：亚克力卡片 + Mica 背景 + 品红强调色
   ============================================================ */

/* ---------- 主题变量 ---------- */
:root {
  --accent: #c2185b;
  --accent-strong: #a81250;
  --accent-soft: rgba(194, 24, 91, 0.10);
  --accent-line: rgba(194, 24, 91, 0.28);

  --bg: #f2f3f5;
  --bg-2: #e9eaee;
  --surface: rgba(255, 255, 255, 0.62);
  --surface-solid: #ffffff;
  --surface-hover: rgba(255, 255, 255, 0.85);
  --border: rgba(0, 0, 0, 0.075);
  --border-strong: rgba(0, 0, 0, 0.14);

  --text: #17181b;
  --text-2: #4b4d54;
  --text-3: #7b7e87;

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05), 0 2px 8px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 8px 28px rgba(0, 0, 0, 0.09);

  --pane-w: 264px;
  --radius: 10px;
  --radius-sm: 7px;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}

html[data-theme="dark"] {
  --accent: #f0578f;
  --accent-strong: #ff7aa8;
  --accent-soft: rgba(240, 87, 143, 0.14);
  --accent-line: rgba(240, 87, 143, 0.38);

  --bg: #16171a;
  --bg-2: #101114;
  --surface: rgba(255, 255, 255, 0.045);
  --surface-solid: #202227;
  --surface-hover: rgba(255, 255, 255, 0.075);
  --border: rgba(255, 255, 255, 0.085);
  --border-strong: rgba(255, 255, 255, 0.16);

  --text: #f1f2f4;
  --text-2: #b4b7bf;
  --text-3: #85888f;

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 14px 40px rgba(0, 0, 0, 0.5);
}

/* ---------- 基础 ---------- */
* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: "Segoe UI Variable Text", "Segoe UI", "Microsoft YaHei UI",
    "Microsoft YaHei", "PingFang SC", system-ui, -apple-system, sans-serif;
  font-size: 15px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { display: block; max-width: 100%; }

a { color: inherit; text-decoration: none; }

button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}

::selection { background: var(--accent); color: #fff; }

.muted { color: var(--text-3); }

/* ---------- Mica 背景 ---------- */
.backdrop {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  background:
    linear-gradient(180deg, var(--bg) 0%, var(--bg-2) 100%);
}

.blob {
  position: absolute;
  border-radius: 999px;
  filter: blur(90px);
  opacity: 0.5;
  will-change: transform;
}

.blob-a {
  width: 620px;
  height: 620px;
  top: -240px;
  right: -120px;
  background: radial-gradient(circle at 40% 40%, var(--accent), transparent 68%);
  opacity: 0.28;
}

.blob-b {
  width: 680px;
  height: 680px;
  bottom: -320px;
  left: 12%;
  background: radial-gradient(circle at 50% 50%, #3b82f6, transparent 66%);
  opacity: 0.14;
}

html[data-theme="dark"] .blob-a { opacity: 0.22; }
html[data-theme="dark"] .blob-b { opacity: 0.10; }

.grain {
  position: absolute;
  inset: 0;
  opacity: 0.22;
  background-image: radial-gradient(rgba(127, 127, 127, 0.28) 0.5px, transparent 0.5px);
  background-size: 3px 3px;
  mix-blend-mode: overlay;
  pointer-events: none;
}

/* ---------- 布局 ---------- */
.app { display: flex; min-height: 100vh; }

/* ---------- 左侧窗格 ---------- */
.pane {
  position: fixed;
  inset: 0 auto 0 0;
  width: var(--pane-w);
  display: flex;
  flex-direction: column;
  gap: 22px;
  padding: 22px 14px 18px;
  border-right: 1px solid var(--border);
  background: color-mix(in srgb, var(--bg) 62%, transparent);
  backdrop-filter: blur(28px) saturate(140%);
  -webkit-backdrop-filter: blur(28px) saturate(140%);
  z-index: 20;
}

.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 6px 8px;
  border-radius: var(--radius-sm);
  transition: background 0.2s var(--ease);
}

.brand:hover { background: var(--surface-hover); }

.brand-avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid var(--border-strong);
  box-shadow: var(--shadow-sm);
}

.brand-text { display: flex; flex-direction: column; line-height: 1.25; }
.brand-text strong { font-size: 14.5px; font-weight: 600; letter-spacing: 0.01em; }
.brand-text em {
  font-style: normal;
  font-size: 11px;
  color: var(--text-3);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

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

.nav-btn {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 9px 12px;
  border-radius: var(--radius-sm);
  color: var(--text-2);
  font-size: 14px;
  transition: background 0.18s var(--ease), color 0.18s var(--ease);
}

.nav-btn svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
  opacity: 0.85;
}

.nav-btn:hover { background: var(--surface-hover); color: var(--text); }

.nav-btn.active {
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 600;
}

.nav-btn.active::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  translate: -8px -50%;
  width: 3px;
  height: 17px;
  border-radius: 3px;
  background: var(--accent);
}

.pane-foot {
  margin-top: auto;
  padding: 0 8px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pane-foot p { margin: 0; font-size: 11.5px; line-height: 1.6; }
.copyright { color: var(--text-3); font-size: 11px; }

/* ---------- 主区域 ---------- */
.main {
  flex: 1;
  min-width: 0;
  margin-left: var(--pane-w);
  display: flex;
  flex-direction: column;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 15;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 58px;
  padding: 0 34px;
  border-bottom: 1px solid var(--border);
  background: color-mix(in srgb, var(--bg) 70%, transparent);
  backdrop-filter: blur(22px) saturate(140%);
  -webkit-backdrop-filter: blur(22px) saturate(140%);
}

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

.topbar-right { display: flex; align-items: center; gap: 10px; }

.segmented {
  display: flex;
  gap: 2px;
  padding: 3px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
}

.segmented button {
  display: grid;
  place-items: center;
  width: 30px;
  height: 26px;
  border-radius: 999px;
  color: var(--text-3);
  transition: background 0.18s var(--ease), color 0.18s var(--ease);
}

.segmented button svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.segmented button:hover { background: var(--surface-hover); color: var(--text); }
.segmented button.active { background: var(--accent); color: #fff; }

.icon-link {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: var(--surface);
  color: var(--text-3);
  transition: color 0.18s var(--ease), border-color 0.18s var(--ease);
}

.icon-link svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
}

.icon-link:hover { color: var(--accent); border-color: var(--accent-line); }

.view {
  flex: 1;
  width: 100%;
  max-width: 1000px;
  margin: 0 auto;
  padding: 40px 34px 56px;
  animation: view-in 0.32s var(--ease);
}

@keyframes view-in {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}

.footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px;
  padding: 20px 34px 26px;
  border-top: 1px solid var(--border);
  color: var(--text-3);
  font-size: 12px;
}

/* ---------- 通用组件 ---------- */
.card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  backdrop-filter: blur(18px) saturate(130%);
  -webkit-backdrop-filter: blur(18px) saturate(130%);
  box-shadow: var(--shadow-sm);
}

.page-head { margin-bottom: 26px; }

.page-head h1 {
  margin: 0 0 8px;
  font-size: 30px;
  font-weight: 650;
  letter-spacing: -0.02em;
  line-height: 1.25;
}

.page-head p {
  margin: 0;
  max-width: 640px;
  color: var(--text-2);
  font-size: 14.5px;
}

.eyebrow {
  margin: 0 0 6px;
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-3);
}

.chip-row { display: flex; flex-wrap: wrap; gap: 8px; }

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text-2);
  font-size: 12px;
  white-space: nowrap;
}

.chip.accent { border-color: var(--accent-line); color: var(--accent); background: var(--accent-soft); }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 18px;
  border: 1px solid var(--border-strong);
  border-radius: 7px;
  background: var(--surface-solid);
  color: var(--text);
  font-size: 13.5px;
  font-weight: 500;
  transition: transform 0.16s var(--ease), box-shadow 0.16s var(--ease),
    background 0.16s var(--ease);
}

.btn:hover { transform: translateY(-1px); box-shadow: var(--shadow-md); }

.btn.primary {
  border-color: transparent;
  background: var(--accent);
  color: #fff;
}

.btn.primary:hover { background: var(--accent-strong); }

.section { margin-top: 44px; }

.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.section-head h2 {
  margin: 0;
  font-size: 17px;
  font-weight: 650;
  letter-spacing: -0.01em;
}

.section-head .more {
  font-size: 12.5px;
  color: var(--text-3);
  transition: color 0.18s var(--ease);
}

.section-head .more:hover { color: var(--accent); }

/* ---------- 首页 ---------- */
.hero {
  display: flex;
  gap: 30px;
  align-items: flex-start;
  padding: 30px;
  border-radius: 14px;
  overflow: hidden;
  position: relative;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(620px 220px at 12% -10%, var(--accent-soft), transparent 70%);
  pointer-events: none;
}

.hero-avatar {
  position: relative;
  flex: none;
  width: 128px;
  height: 128px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid var(--border-strong);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.28), 0 0 0 6px var(--surface);
}

.hero-avatar { z-index: 1; }

.hero-body { position: relative; z-index: 1; min-width: 0; }

.hero h1 {
  margin: 0 0 6px;
  font-size: 34px;
  font-weight: 680;
  letter-spacing: -0.025em;
  line-height: 1.15;
}

.hero .role {
  margin: 0 0 12px;
  color: var(--text-2);
  font-size: 14.5px;
}

.hero .bio {
  margin: 0 0 18px;
  max-width: 560px;
  color: var(--text-2);
  font-size: 14px;
  line-height: 1.8;
}

/* 简介下方的两个入口卡片：邮件 / GitHub */
.hero-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  max-width: 440px;
  margin: 0 0 20px;
}

.hero-action {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  padding: 10px 13px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  transition: border-color 0.18s var(--ease), background 0.18s var(--ease),
    transform 0.18s var(--ease);
}

.hero-action:hover {
  border-color: var(--accent-line);
  background: var(--surface-hover);
  transform: translateY(-1px);
}

.hero-action-ico {
  flex: none;
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--accent-soft);
  color: var(--accent);
}

.hero-action-ico svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.hero-action-ico svg.gh {
  width: 17px;
  height: 17px;
  fill: currentColor;
  stroke: none;
}

.hero-action-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
  line-height: 1.35;
}

.hero-action-text strong {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text);
}

.hero-action-text em {
  font-style: normal;
  font-size: 11.5px;
  color: var(--text-3);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.lbl-short { display: none; }

/* 轻提示条（复制邮箱后弹出） */
#toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  z-index: 9998;
  width: max-content;
  max-width: calc(100vw - 32px);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transform: translate(-50%, 12px);
  padding: 10px 18px;
  border-radius: 999px;
  border: 1px solid var(--border-strong);
  background: color-mix(in srgb, var(--surface-solid) 92%, transparent);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: var(--text);
  font-size: 13px;
  box-shadow: var(--shadow-md);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s var(--ease), transform 0.2s var(--ease);
}

#toast.show { opacity: 1; transform: translate(-50%, 0); }

.hero .btn-row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }

.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 14px;
}

.stat {
  padding: 16px 18px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--surface);
  transition: border-color 0.18s var(--ease), background 0.18s var(--ease),
    transform 0.18s var(--ease);
}

.stat:hover {
  border-color: var(--accent-line);
  background: var(--surface-hover);
  transform: translateY(-1px);
}

.stat:hover span { color: var(--accent); }

.stat b {
  display: block;
  font-size: 24px;
  font-weight: 650;
  letter-spacing: -0.02em;
  color: var(--accent);
  line-height: 1.2;
}

.stat span { font-size: 12px; color: var(--text-3); }

/* 折腾清单 */
.tinker-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }

#tinkering { scroll-margin-top: 78px; }

.tinker {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  transition: border-color 0.18s var(--ease), background 0.18s var(--ease);
}

.tinker:hover { border-color: var(--accent-line); background: var(--surface-hover); }

.tinker-ico {
  flex: none;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 7px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 14px;
  font-weight: 600;
}

.tinker h3 { margin: 0 0 2px; font-size: 13.5px; font-weight: 600; }
.tinker p { margin: 0; font-size: 12.5px; color: var(--text-3); line-height: 1.6; }

/* ---------- 文章列表 ---------- */
.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 8px;
}

.filter {
  padding: 6px 13px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text-2);
  font-size: 12.5px;
  transition: all 0.16s var(--ease);
}

.filter:hover { border-color: var(--border-strong); color: var(--text); }

.filter.active {
  background: var(--accent);
  border-color: transparent;
  color: #fff;
}

.post-list { margin-top: 14px; display: flex; flex-direction: column; }

.post-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 20px;
  align-items: center;
  padding: 20px 16px;
  margin: 0 -16px;
  border-bottom: 1px solid var(--border);
  border-radius: var(--radius);
  transition: background 0.18s var(--ease);
}

.post-row:hover { background: var(--surface-hover); }

.post-row h2 {
  margin: 0 0 6px;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.5;
}

.post-row:hover h2 { color: var(--accent); }

.post-row .excerpt {
  margin: 0 0 10px;
  color: var(--text-3);
  font-size: 13px;
  line-height: 1.7;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.post-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  color: var(--text-3);
  font-size: 12px;
}

.dot { width: 3px; height: 3px; border-radius: 50%; background: currentColor; opacity: 0.5; }

.arrow {
  width: 22px;
  height: 22px;
  color: var(--text-3);
  opacity: 0;
  transform: translateX(-4px);
  transition: all 0.2s var(--ease);
}

.post-row:hover .arrow { opacity: 1; transform: none; color: var(--accent); }

.empty {
  padding: 48px 0;
  text-align: center;
  color: var(--text-3);
  font-size: 13.5px;
}

/* ---------- 文章详情 ---------- */
.back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 22px;
  color: var(--text-3);
  font-size: 13px;
  transition: color 0.18s var(--ease);
}

.back:hover { color: var(--accent); }

.back svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

.article-head { padding-bottom: 22px; border-bottom: 1px solid var(--border); margin-bottom: 28px; }

.article-head h1 {
  margin: 10px 0 12px;
  font-size: 32px;
  font-weight: 680;
  letter-spacing: -0.025em;
  line-height: 1.3;
}

.article-head .post-meta { font-size: 12.5px; }

.prose { max-width: 720px; font-size: 15px; line-height: 1.95; color: var(--text-2); }

.prose > * + * { margin-top: 1.1em; }

.prose h2 {
  margin-top: 2.2em;
  margin-bottom: 0.7em;
  font-size: 19px;
  font-weight: 650;
  color: var(--text);
  letter-spacing: -0.01em;
  scroll-margin-top: 80px;
}

.prose h3 { margin-top: 1.8em; font-size: 16px; color: var(--text); }

.prose p { margin: 0; }

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

.prose ul, .prose ol { padding-left: 1.35em; margin: 0; }
.prose li { margin: 0.4em 0; }

.prose blockquote {
  margin: 1.4em 0;
  padding: 2px 0 2px 16px;
  border-left: 2px solid var(--accent);
  color: var(--text-3);
}

.prose code {
  padding: 0.15em 0.4em;
  border-radius: 4px;
  background: var(--surface-hover);
  border: 1px solid var(--border);
  font-family: "Cascadia Code", "JetBrains Mono", ui-monospace, Consolas, monospace;
  font-size: 0.88em;
  color: var(--text);
}

.prose pre {
  margin: 1.4em 0;
  padding: 16px 18px;
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: color-mix(in srgb, var(--bg-2) 82%, #000);
  font-size: 12.5px;
  line-height: 1.75;
}

.prose pre code {
  padding: 0;
  border: 0;
  background: none;
  font-size: inherit;
  color: #d8dee9;
}

html[data-theme="light"] .prose pre code { color: #e6edf3; }

.article-foot {
  margin-top: 44px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
  justify-content: space-between;
}

.post-nav { display: flex; flex-wrap: wrap; gap: 8px 22px; }

.post-nav a {
  color: var(--text-3);
  font-size: 12.5px;
  transition: color 0.18s var(--ease);
}

.post-nav a:hover { color: var(--accent); }

/* ---------- 技能 ---------- */
.skill-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }

.skill-card { padding: 20px 20px 22px; }

.skill-card h2 {
  margin: 0 0 4px;
  font-size: 14.5px;
  font-weight: 650;
}

.skill-card .sub { margin: 0 0 16px; font-size: 12px; color: var(--text-3); }

.skill { margin-bottom: 14px; }

.skill:last-child { margin-bottom: 0; }

.skill-top {
  display: flex;
  justify-content: space-between;
  font-size: 12.5px;
  color: var(--text-2);
  margin-bottom: 6px;
}

.skill-top span:last-child { color: var(--text-3); font-variant-numeric: tabular-nums; }

.bar {
  height: 5px;
  border-radius: 999px;
  background: var(--surface-hover);
  overflow: hidden;
}

.bar i {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--accent), color-mix(in srgb, var(--accent) 55%, #7c5cff));
  transform-origin: left;
  animation: bar-in 0.9s var(--ease) both;
}

@keyframes bar-in { from { transform: scaleX(0); } to { transform: scaleX(1); } }

.learning {
  margin-top: 12px;
  padding: 18px 20px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  align-items: center;
  font-size: 13px;
  color: var(--text-2);
}

/* ---------- 关于 ---------- */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 260px;
  gap: 32px;
  align-items: start;
}

.about-body p { margin: 0 0 1em; color: var(--text-2); font-size: 14.5px; line-height: 1.9; }

.portrait {
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-md);
  background: #fff;
}

.portrait img { width: 100%; height: auto; aspect-ratio: 3 / 4; object-fit: cover; }

.portrait figcaption {
  padding: 9px 12px;
  font-size: 11.5px;
  color: var(--text-3);
  background: var(--surface);
  border-top: 1px solid var(--border);
}

.timeline { list-style: none; margin: 0; padding: 0; }

.timeline li {
  position: relative;
  padding: 0 0 22px 26px;
  border-left: 1px solid var(--border);
}

.timeline li:last-child { padding-bottom: 0; border-color: transparent; }

.timeline li::before {
  content: "";
  position: absolute;
  left: -4.5px;
  top: 6px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-soft);
}

.timeline time {
  display: block;
  font-size: 11.5px;
  letter-spacing: 0.06em;
  color: var(--text-3);
  text-transform: uppercase;
}

.timeline strong { display: block; margin: 2px 0 3px; font-size: 14px; font-weight: 600; }
.timeline p { margin: 0; font-size: 13px; color: var(--text-3); line-height: 1.7; }

.contact-list { display: grid; gap: 8px; }

.contact {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  font-size: 13px;
  transition: border-color 0.18s var(--ease);
}

.contact:hover { border-color: var(--accent-line); }
.contact span { color: var(--text-3); font-size: 12px; }

/* ---------- 游戏 ---------- */
.game-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.game-card {
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s var(--ease), border-color 0.2s var(--ease);
}

.game-card:hover { transform: translateY(-2px); border-color: var(--accent-line); }

.game-cover {
  position: relative;
  aspect-ratio: 16 / 9;
  display: grid;
  place-items: center;
  overflow: hidden;
}

.game-cover::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(120% 90% at 15% -10%, rgba(255, 255, 255, 0.2), transparent 62%);
}

.game-img {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s var(--ease);
}

.game-card:hover .game-img { transform: scale(1.04); }

.game-cover.has-img::before { display: none; }

.game-cover.has-img::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.38) 0%,
    rgba(0, 0, 0, 0.04) 34%,
    rgba(0, 0, 0, 0.32) 60%,
    rgba(0, 0, 0, 0.86) 100%
  );
}

.game-cover.has-img .cover-badge,
.game-cover.has-img .cover-en { z-index: 3; }

.game-cover.has-img .cover-badge { background: rgba(0, 0, 0, 0.48); }

/* 有官方封面时，英文名通常已经印在图上了，不重复显示 */
.game-cover.has-img .cover-en { display: none; }

.cover-glyph {
  position: absolute;
  right: -6px;
  bottom: -26px;
  font-size: 132px;
  font-weight: 800;
  line-height: 1;
  color: rgba(255, 255, 255, 0.16);
  letter-spacing: -0.04em;
  user-select: none;
  pointer-events: none;
}

.cover-en {
  position: absolute;
  left: 12px;
  bottom: 10px;
  z-index: 2;
  font-size: 10.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.72);
}

.cover-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 2;
  padding: 3px 9px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.34);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: #fff;
  font-size: 10.5px;
  letter-spacing: 0.02em;
}

.game-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 14px 16px 16px;
}

.game-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.game-title-row h2 {
  margin: 0;
  font-size: 15px;
  font-weight: 650;
  letter-spacing: -0.01em;
  line-height: 1.4;
}

.game-title-row .chip { flex: none; padding: 2px 8px; font-size: 11px; }

.game-meta { margin: 0; font-size: 11.5px; color: var(--text-3); }

.game-note {
  margin: 2px 0 0;
  font-size: 12.5px;
  color: var(--text-2);
  line-height: 1.7;
  white-space: pre-line;
}

/* ---------- 番剧 ---------- */
.anime-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  align-items: start;
}

.anime-card {
  position: relative;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  transition: transform 0.2s var(--ease), border-color 0.2s var(--ease);
}

.anime-card:hover { transform: translateY(-2px); border-color: var(--accent-line); }

.anime-cover {
  position: relative;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 3px;
  padding: 14px;
}

.anime-cover::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(110% 80% at 20% -10%, rgba(255, 255, 255, 0.18), transparent 62%);
}

.anime-cover::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.3) 0%,
    rgba(0, 0, 0, 0) 26%,
    rgba(0, 0, 0, 0.26) 50%,
    rgba(0, 0, 0, 0.72) 76%,
    rgba(0, 0, 0, 0.92) 100%
  );
}

.anime-img {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s var(--ease);
}

.anime-card:hover .anime-img { transform: scale(1.04); }

.anime-cover.has-img::before { display: none; }
.anime-cover.has-img .cover-glyph { display: none; }

.anime-cover .cover-glyph {
  font-size: 150px;
  left: -12px;
  top: -30px;
  right: auto;
  bottom: auto;
}

.anime-title {
  position: relative;
  z-index: 2;
  margin: 0;
  font-size: 14.5px;
  font-weight: 650;
  line-height: 1.4;
  color: #fff;
  letter-spacing: -0.01em;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.55), 0 2px 18px rgba(0, 0, 0, 0.5);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.anime-sub {
  position: relative;
  z-index: 2;
  margin: 0;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.82);
  letter-spacing: 0.02em;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6);
}

.anime-cover .cover-badge { top: 10px; right: 10px; left: auto; bottom: auto; z-index: 3; }
.anime-cover .cover-badge.hot { background: var(--accent); border: 1px solid rgba(255, 255, 255, 0.15); }

/* ---------- 首页：游戏与番剧入口 ---------- */
.hobby-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }

.hobby {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 18px 20px;
  transition: border-color 0.18s var(--ease), background 0.18s var(--ease);
}

.hobby:hover { border-color: var(--accent-line); background: var(--surface-hover); }

.hobby-kicker {
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-3);
}

.hobby strong { font-size: 20px; font-weight: 650; color: var(--accent); line-height: 1.3; }

.hobby p {
  margin: 0;
  font-size: 12.5px;
  color: var(--text-2);
  line-height: 1.7;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.hobby-more { margin-top: auto; padding-top: 8px; font-size: 12px; color: var(--text-3); }
.hobby:hover .hobby-more { color: var(--accent); }

/* ---------- 评论 ---------- */
.comments {
  margin-top: 46px;
  padding-top: 26px;
  border-top: 1px solid var(--border);
}

.comments-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.comments-head h2 {
  margin: 0;
  font-size: 17px;
  font-weight: 650;
  letter-spacing: -0.01em;
}

.comments-head .muted { font-size: 12px; }

#waline { max-width: 720px; margin-top: 4px; }

.comment-hint {
  margin: 0 0 12px;
  max-width: 660px;
  font-size: 12.5px;
  line-height: 1.85;
  color: var(--text-3);
}

#commentText {
  display: block;
  width: 100%;
  max-width: 680px;
  min-height: 110px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  font: inherit;
  font-size: 13.5px;
  line-height: 1.75;
  resize: vertical;
  transition: border-color 0.18s var(--ease), box-shadow 0.18s var(--ease);
}

.comment-input {
  display: block;
  width: 100%;
  max-width: 680px;
  margin-bottom: 10px;
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  font: inherit;
  font-size: 13.5px;
  transition: border-color 0.18s var(--ease), box-shadow 0.18s var(--ease);
}

.comment-input::placeholder { color: var(--text-3); }

.comment-input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.comment-btns { display: flex; flex-wrap: wrap; gap: 8px; }

#commentText::placeholder { color: var(--text-3); }

#commentText:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.comment-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  max-width: 680px;
  margin-top: 10px;
}

.comment-actions .muted { font-size: 12px; }

/* ---------- 响应式 ---------- */
@media (max-width: 1180px) {
  .game-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .anime-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 980px) {
  .hero { flex-direction: column; text-align: center; align-items: center; }
  .hero .chip-row, .hero .btn-row { justify-content: center; }
  .hero .bio { margin-inline: auto; }
  .hero-actions { margin-inline: auto; text-align: left; }
  .tinker-list, .skill-grid, .hobby-row { grid-template-columns: 1fr; }
  .about-grid { grid-template-columns: 1fr; }
  .portrait { max-width: 280px; }
}

@media (max-width: 620px) {
  .game-grid { grid-template-columns: 1fr; }
  .anime-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  /* 三张入口卡始终排成一排：收窄内边距、隐藏副标题、标题换短文案 */
  .hero-actions { gap: 6px; max-width: none; }
  .hero-action { padding: 8px; gap: 7px; }
  .hero-action-ico { width: 26px; height: 26px; border-radius: 7px; }
  .hero-action-ico svg { width: 14px; height: 14px; }
  .hero-action-ico svg.gh { width: 15px; height: 15px; }
  .hero-action-text strong { font-size: 12px; }
  .hero-action-text em { display: none; }
  .lbl-long { display: none; }
  .lbl-short { display: inline; }
}

@media (max-width: 820px) {
  :root { --pane-w: 0px; }

  .app { flex-direction: column; }

  .pane {
    position: sticky;
    inset: 0 0 auto 0;
    width: 100%;
    height: auto;
    flex-direction: row;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    border-right: 0;
    border-bottom: 1px solid var(--border);
    overflow-x: auto;
    scrollbar-width: none;
  }

  .pane::-webkit-scrollbar { display: none; }

  .brand { padding: 4px 6px 4px 0; flex: none; }
  .brand-avatar { width: 32px; height: 32px; }
  .brand-text em { display: none; }

  .nav { flex-direction: row; gap: 4px; flex: 1; }

  .nav-btn { padding: 7px 11px; white-space: nowrap; gap: 8px; font-size: 13px; }
  .nav-btn svg { width: 16px; height: 16px; }
  .nav-btn.active::before { display: none; }

  .pane-foot { display: none; }

  .main { margin-left: 0; }

  .topbar { position: static; padding: 0 18px; height: 52px; }

  .view { padding: 28px 18px 44px; }

  .footer { padding: 18px; flex-direction: column; }

  .stats { grid-template-columns: 1fr; }
  .stat { display: flex; align-items: baseline; gap: 10px; padding: 12px 16px; }
  .stat b { font-size: 18px; }

  .hero { padding: 24px 18px; }
  .hero h1 { font-size: 27px; }
  .hero-avatar { width: 104px; height: 104px; }

  .post-row { grid-template-columns: 1fr; gap: 4px; padding: 16px 10px; margin: 0 -10px; }
  .arrow { display: none; }

  .article-head h1 { font-size: 25px; }
  .page-head h1 { font-size: 25px; }
}

@media (max-width: 480px) {
  .pane { gap: 6px; padding: 10px; }
  .brand { padding-right: 0; }
  .brand-text strong { font-size: 13.5px; }
  .nav { gap: 2px; }
  .nav-btn { gap: 0; padding: 6px 8px; font-size: 12.5px; }
  .nav-btn svg { display: none; }
  .topbar { padding: 0 12px; }
  .view { padding: 24px 14px 40px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
  html { scroll-behavior: auto; }
}
