/* ============================================================
   sasakure.uk 风格个人博客 — 全局样式
   视觉语言：纸白 × 雾蓝 × 杏橙 × 奶黄，纤细线条，童话机械宇宙
   ============================================================ */

/* ---------- 设计令牌 ---------- */
:root {
  /* 亮色（纸白模式） */
  --bg: #F5F0E4;
  --bg-soft: #FBF7EC;
  --card: #FFFDF6;
  --ink: #3A352B;
  --ink-soft: #857C6A;
  --line: #E4DCC8;
  --blue: #8FB6C9;
  --blue-deep: #54788C;
  --blue-mist: #DCE9EF;
  --apricot: #E5A273;
  --apricot-deep: #C4763F;
  --apricot-mist: #F7E3D2;
  --butter: #F0D69C;
  --butter-mist: #F9EFD8;
  --red: #C25B3F;
  --star: #E2A93E;
  --nav-bg: rgba(251, 247, 236, 0.86);
  --shadow: 0 6px 24px rgba(90, 78, 52, 0.08);
  --shadow-hover: 0 12px 36px rgba(90, 78, 52, 0.14);
  --grid-line: rgba(120, 110, 85, 0.07);

  --font-serif: "Noto Serif JP", "Songti SC", serif;
  --font-round: "Zen Maru Gothic", "PingFang SC", sans-serif;
  --font-en: "Jost", "Avenir", sans-serif;

  --radius: 16px;
  --nav-h: 64px;
}

[data-theme="dark"] {
  /* 暗色（夜空模式） */
  --bg: #1B2740;
  --bg-soft: #22314C;
  --card: #253551;
  --ink: #EDE6D6;
  --ink-soft: #A8B2C4;
  --line: #3A4C6E;
  --blue: #8FB6C9;
  --blue-deep: #A8CBDE;
  --blue-mist: #2E4360;
  --apricot: #E5A273;
  --apricot-deep: #F0B98D;
  --apricot-mist: #4A3B33;
  --butter: #F0D69C;
  --butter-mist: #4A422F;
  --red: #E08366;
  --star: #F0C25E;
  --nav-bg: rgba(27, 39, 64, 0.88);
  --shadow: 0 6px 24px rgba(0, 0, 0, 0.28);
  --shadow-hover: 0 12px 36px rgba(0, 0, 0, 0.38);
  --grid-line: rgba(200, 210, 230, 0.05);
}

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

html { scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + 20px); }

body {
  font-family: var(--font-round);
  background: var(--bg);
  color: var(--ink);
  line-height: 1.75;
  font-size: 15px;
  transition: background 0.4s, color 0.4s;
  overflow-x: hidden;
}

/* 方格纸纹理背景 */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    repeating-linear-gradient(0deg, var(--grid-line) 0 1px, transparent 1px 56px),
    repeating-linear-gradient(90deg, var(--grid-line) 0 1px, transparent 1px 56px);
  pointer-events: none;
}

/* 漂浮星点 canvas */
#petals-canvas {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
}

a { color: inherit; text-decoration: none; transition: color 0.25s; }
img { display: block; max-width: 100%; }
ul, ol { list-style: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }
::selection { background: var(--apricot); color: #fff; }

.wrap { max-width: 1200px; margin: 0 auto; padding: 0 24px; }

/* ---------- 顶部导航 ---------- */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  height: var(--nav-h);
  background: var(--nav-bg);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  height: 100%;
  display: flex;
  align-items: center;
  gap: 28px;
}
.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-serif);
  font-weight: 900;
  font-size: 19px;
  letter-spacing: 0.5px;
  flex-shrink: 0;
}
.nav-logo .logo-mark {
  width: 34px; height: 34px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--blue), var(--blue-deep));
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 15px;
  box-shadow: inset 0 0 0 1.5px rgba(255,255,255,.35);
}
.nav-logo small {
  font-family: var(--font-en);
  font-size: 10px;
  letter-spacing: 2.5px;
  color: var(--ink-soft);
  display: block;
  line-height: 1;
  margin-top: 2px;
}
.nav-menu { display: flex; gap: 4px; margin-left: auto; }
.nav-menu a {
  position: relative;
  padding: 8px 14px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 500;
  color: var(--ink-soft);
  display: flex;
  align-items: center;
  gap: 6px;
}
.nav-menu a .jp { font-size: 11px; opacity: 0.7; }
.nav-menu a:hover { color: var(--apricot-deep); background: var(--apricot-mist); }
.nav-menu a.active { color: var(--blue-deep); background: var(--blue-mist); }
.nav-menu a.active::after {
  content: "✦";
  position: absolute;
  top: 2px; right: 6px;
  font-size: 9px;
  color: var(--star);
}
.nav-tools { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.nav-tools button, .nav-tools a {
  width: 36px; height: 36px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--ink-soft);
  transition: all 0.25s;
}
.nav-tools button:hover, .nav-tools a:hover {
  color: var(--apricot-deep);
  border-color: var(--apricot);
  transform: translateY(-2px);
}
.nav-tools svg { width: 17px; height: 17px; }
.nav-burger { display: none !important; }

/* 移动端菜单 */
.mobile-menu {
  position: fixed;
  top: var(--nav-h); left: 0; right: 0;
  z-index: 99;
  background: var(--bg-soft);
  border-bottom: 1px solid var(--line);
  padding: 16px 24px 24px;
  display: none;
  transform: translateY(-8px);
  opacity: 0;
  transition: all 0.3s;
}
.mobile-menu.open { display: block; transform: none; opacity: 1; }
.mobile-menu a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px 16px;
  border-radius: 12px;
  font-weight: 500;
  border: 1px solid transparent;
}
.mobile-menu a:hover { border-color: var(--line); background: var(--card); }
.mobile-menu a .jp { color: var(--ink-soft); font-size: 12px; }

/* ---------- Hero（首页大图） ---------- */
.hero {
  position: relative;
  min-height: 560px;
  margin-top: var(--nav-h);
  display: flex;
  align-items: center;
  overflow: hidden;
  background: #22314C;
}
.hero-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center 30%;
  transform: scale(1.06);
  transition: transform 1.2s ease-out;
  filter: saturate(0.92);
}
.hero:hover .hero-bg { transform: scale(1.1); }
.hero-veil {
  position: absolute; inset: 0;
  background:
    linear-gradient(100deg, rgba(20,30,52,0.82) 0%, rgba(20,30,52,0.45) 42%, rgba(20,30,52,0.08) 70%),
    linear-gradient(0deg, rgba(20,30,52,0.5), transparent 40%);
}
.hero-inner {
  position: relative;
  z-index: 2;
  max-width: 1200px;
  margin: 0 auto;
  padding: 80px 24px;
  width: 100%;
}
.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-en);
  font-size: 12px;
  letter-spacing: 3px;
  color: var(--butter);
  border: 1px solid rgba(240, 214, 156, 0.45);
  padding: 6px 16px;
  border-radius: 99px;
  margin-bottom: 26px;
  background: rgba(20, 30, 52, 0.35);
  backdrop-filter: blur(6px);
}
.hero h1 {
  font-family: var(--font-serif);
  font-weight: 900;
  font-size: clamp(30px, 4.6vw, 52px);
  line-height: 1.5;
  color: #FBF7EC;
  text-shadow: 0 2px 24px rgba(15, 22, 40, 0.5);
  max-width: 640px;
  margin-bottom: 10px;
}
.hero h1 .accent {
  color: var(--butter);
  position: relative;
  white-space: nowrap;
}
.hero h1 .accent::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 4px;
  height: 10px;
  background: var(--apricot);
  opacity: 0.35;
  z-index: -1;
  border-radius: 4px;
}
.hero-sub {
  color: rgba(251, 247, 236, 0.82);
  font-size: 15px;
  max-width: 520px;
  margin: 18px 0 36px;
  line-height: 2;
}
.hero-btns { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-scroll {
  position: absolute;
  bottom: 26px; left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  color: rgba(251,247,236,0.65);
  font-size: 11px;
  letter-spacing: 2px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}
.hero-scroll::after {
  content: "";
  width: 1px; height: 34px;
  background: linear-gradient(180deg, var(--butter), transparent);
  animation: scrollHint 1.8s ease-in-out infinite;
}
@keyframes scrollHint {
  0% { transform: scaleY(0); transform-origin: top; }
  45% { transform: scaleY(1); transform-origin: top; }
  55% { transform: scaleY(1); transform-origin: bottom; }
  100% { transform: scaleY(0); transform-origin: bottom; }
}

/* ---------- 按钮 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 26px;
  border-radius: 99px;
  font-weight: 700;
  font-size: 14px;
  transition: all 0.28s;
  border: 1.5px solid transparent;
}
.btn-primary {
  background: linear-gradient(135deg, var(--apricot), var(--apricot-deep));
  color: #fff;
  box-shadow: 0 6px 20px rgba(196, 118, 63, 0.35);
}
.btn-primary:hover { transform: translateY(-3px); box-shadow: 0 10px 28px rgba(196, 118, 63, 0.45); }
.btn-ghost {
  border-color: rgba(251, 247, 236, 0.5);
  color: #FBF7EC;
  background: rgba(20, 30, 52, 0.25);
  backdrop-filter: blur(6px);
}
.btn-ghost:hover { border-color: var(--butter); color: var(--butter); transform: translateY(-3px); }
.btn-line {
  border-color: var(--line);
  color: var(--ink-soft);
  background: var(--card);
}
.btn-line:hover { border-color: var(--apricot); color: var(--apricot-deep); }

/* ---------- 区块标题 ---------- */
.section { padding: 64px 0 8px; }
.section-head {
  display: flex;
  align-items: baseline;
  gap: 16px;
  margin-bottom: 36px;
}
.section-head h2 {
  font-family: var(--font-serif);
  font-weight: 900;
  font-size: 26px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.section-head h2::before {
  content: "✦";
  color: var(--star);
  font-size: 18px;
}
.section-head .en {
  font-family: var(--font-en);
  font-size: 12px;
  letter-spacing: 3px;
  color: var(--ink-soft);
  text-transform: uppercase;
}
.section-head .more {
  margin-left: auto;
  font-size: 13px;
  color: var(--ink-soft);
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.section-head .more:hover { color: var(--apricot-deep); }

/* ---------- 主体布局 ---------- */
.layout {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 32px;
  align-items: start;
  padding-bottom: 48px;
}

/* ---------- 文章卡片 ---------- */
.post-list { display: grid; gap: 26px; }
.post-card {
  display: grid;
  grid-template-columns: 240px 1fr;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: all 0.35s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.post-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-hover);
  border-color: var(--apricot);
}
.post-card .thumb {
  position: relative;
  min-height: 190px;
  overflow: hidden;
}
.post-card .thumb img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.6s;
}
.post-card:hover .thumb img { transform: scale(1.08); }
.post-card .thumb .sticky-tag {
  position: absolute;
  top: 12px; left: 12px;
  background: var(--apricot);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 99px;
  letter-spacing: 1px;
  box-shadow: 0 3px 10px rgba(196, 118, 63, 0.4);
}
.post-card .body { padding: 22px 26px 20px; display: flex; flex-direction: column; }
.post-card .meta {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  font-size: 12px;
  color: var(--ink-soft);
  margin-bottom: 10px;
}
.post-card .meta span { display: inline-flex; align-items: center; gap: 5px; }
.post-card .meta svg { width: 13px; height: 13px; }
.post-card h3 {
  font-family: var(--font-serif);
  font-size: 19px;
  font-weight: 700;
  line-height: 1.55;
  margin-bottom: 8px;
}
.post-card:hover h3 { color: var(--apricot-deep); }
.post-card .excerpt {
  color: var(--ink-soft);
  font-size: 13.5px;
  line-height: 1.9;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.post-card .tags-row { margin-top: auto; padding-top: 14px; display: flex; gap: 8px; flex-wrap: wrap; }
.chip {
  font-size: 11px;
  padding: 3px 11px;
  border-radius: 99px;
  background: var(--blue-mist);
  color: var(--blue-deep);
  border: 1px solid transparent;
  transition: all 0.25s;
}
.chip:hover { border-color: var(--blue); }
.chip.apricot { background: var(--apricot-mist); color: var(--apricot-deep); }
.chip.butter { background: var(--butter-mist); color: #A87B2E; }

/* 置顶大卡 */
.feature-card {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  min-height: 300px;
  display: flex;
  align-items: flex-end;
  box-shadow: var(--shadow);
  transition: all 0.35s;
  margin-bottom: 30px;
}
.feature-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-hover); }
.feature-card img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 0.8s; }
.feature-card:hover img { transform: scale(1.06); }
.feature-card::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(0deg, rgba(25,32,50,0.88) 0%, rgba(25,32,50,0.25) 55%, transparent 80%);
}
.feature-card .content { position: relative; z-index: 2; padding: 34px; color: #FBF7EC; }
.feature-card .badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--butter);
  color: #5C4718;
  font-size: 11px;
  font-weight: 900;
  padding: 5px 14px;
  border-radius: 99px;
  margin-bottom: 14px;
  letter-spacing: 1px;
}
.feature-card h3 {
  font-family: var(--font-serif);
  font-size: 25px;
  font-weight: 900;
  margin-bottom: 8px;
  text-shadow: 0 2px 16px rgba(0,0,0,0.4);
}
.feature-card p { font-size: 13.5px; opacity: 0.85; max-width: 560px; line-height: 1.9; }
.feature-card .meta { display: flex; gap: 16px; margin-top: 14px; font-size: 12px; opacity: 0.75; }

/* ---------- 侧边栏 ---------- */
.sidebar { display: grid; gap: 26px; position: sticky; top: calc(var(--nav-h) + 24px); }
.widget {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow);
}
.widget-title {
  font-family: var(--font-serif);
  font-weight: 900;
  font-size: 16px;
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 18px;
  padding-bottom: 14px;
  border-bottom: 1px dashed var(--line);
}
.widget-title .deco { color: var(--apricot); font-size: 13px; }

/* 个人卡片 */
.profile-card { text-align: center; position: relative; overflow: hidden; }
.profile-card::before {
  content: "";
  position: absolute;
  top: -40px; left: 50%;
  transform: translateX(-50%);
  width: 220px; height: 160px;
  background: radial-gradient(ellipse at center, var(--blue-mist), transparent 70%);
  opacity: 0.8;
  pointer-events: none;
}
.avatar-ring {
  width: 96px; height: 96px;
  margin: 0 auto 14px;
  border-radius: 50%;
  padding: 4px;
  background: conic-gradient(from 0deg, var(--apricot), var(--butter), var(--blue), var(--apricot));
  animation: spinRing 8s linear infinite;
  position: relative;
}
@keyframes spinRing { to { transform: rotate(360deg); } }
.avatar-ring img, .avatar-ring .avatar-inner {
  width: 100%; height: 100%;
  border-radius: 50%;
  background: var(--bg-soft);
  display: grid;
  place-items: center;
  animation: spinRing 8s linear infinite reverse;
  overflow: hidden;
}
.avatar-ring .avatar-inner svg { width: 62px; height: 62px; }
.profile-card .name {
  font-family: var(--font-serif);
  font-size: 20px;
  font-weight: 900;
}
.profile-card .name-en {
  font-family: var(--font-en);
  font-size: 11px;
  letter-spacing: 2.5px;
  color: var(--ink-soft);
  margin: 3px 0 10px;
}
.profile-card .sign {
  font-size: 12.5px;
  color: var(--ink-soft);
  line-height: 1.9;
  padding: 12px 14px;
  background: var(--bg-soft);
  border-radius: 12px;
  border: 1px dashed var(--line);
  margin-bottom: 16px;
}
.profile-stats {
  display: flex;
  justify-content: space-around;
  border-top: 1px dashed var(--line);
  padding-top: 16px;
}
.profile-stats .num {
  font-family: var(--font-en);
  font-size: 19px;
  font-weight: 600;
  color: var(--apricot-deep);
}
.profile-stats .lbl { font-size: 11px; color: var(--ink-soft); }
.social-row { display: flex; justify-content: center; gap: 10px; }
.social-row a {
  width: 36px; height: 36px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  color: var(--ink-soft);
  background: var(--bg-soft);
  transition: all 0.25s;
}
.social-row a:hover {
  color: #fff;
  background: linear-gradient(135deg, var(--apricot), var(--apricot-deep));
  border-color: transparent;
  transform: translateY(-3px);
}
.social-row svg { width: 16px; height: 16px; }

/* 音乐播放器 */
.music-widget { padding-bottom: 18px; }
.music-disc {
  width: 100%;
  aspect-ratio: 1;
  max-width: 150px;
  margin: 0 auto 16px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 50%, #2A3550 8%, transparent 9%),
    radial-gradient(circle at 50% 50%, #4A5878 14%, transparent 15%),
    conic-gradient(from 0deg, #31405E, #4A5878, #31405E, #4A5878, #31405E);
  box-shadow: 0 8px 26px rgba(30, 42, 70, 0.35), inset 0 0 0 1px rgba(255,255,255,0.12);
  display: grid;
  place-items: center;
  position: relative;
}
.music-disc.spinning { animation: spinRing 6s linear infinite; }
.music-disc .disc-cover {
  width: 62%; height: 62%;
  border-radius: 50%;
  overflow: hidden;
  border: 2px solid rgba(255,255,255,0.2);
}
.music-disc .disc-cover img { width: 100%; height: 100%; object-fit: cover; }
.music-info { text-align: center; margin-bottom: 12px; }
.music-info .track {
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: 15px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.music-info .artist { font-size: 11.5px; color: var(--ink-soft); margin-top: 2px; }
.music-progress {
  height: 4px;
  border-radius: 99px;
  background: var(--line);
  overflow: hidden;
  margin-bottom: 4px;
  cursor: pointer;
}
.music-progress .bar {
  height: 100%;
  width: 0;
  border-radius: 99px;
  background: linear-gradient(90deg, var(--apricot), var(--butter));
  transition: width 0.3s linear;
}
.music-times { display: flex; justify-content: space-between; font-size: 10.5px; color: var(--ink-soft); font-family: var(--font-en); margin-bottom: 12px; }
.music-ctrls { display: flex; align-items: center; justify-content: center; gap: 18px; margin-bottom: 14px; }
.music-ctrls button {
  width: 34px; height: 34px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: var(--ink-soft);
  transition: all 0.25s;
}
.music-ctrls button:hover { color: var(--apricot-deep); background: var(--apricot-mist); }
.music-ctrls .play-btn {
  width: 46px; height: 46px;
  background: linear-gradient(135deg, var(--apricot), var(--apricot-deep));
  color: #fff;
  box-shadow: 0 5px 16px rgba(196, 118, 63, 0.4);
}
.music-ctrls .play-btn:hover { transform: scale(1.08); color: #fff; }
.music-ctrls svg { width: 15px; height: 15px; }
.music-ctrls .play-btn svg { width: 17px; height: 17px; }
.music-viz { display: flex; align-items: flex-end; justify-content: center; gap: 3px; height: 26px; margin-bottom: 12px; }
.music-viz i {
  width: 3.5px;
  border-radius: 99px;
  background: linear-gradient(180deg, var(--apricot), var(--butter));
  height: 20%;
  transition: height 0.25s;
}
.music-widget.playing .music-viz i { animation: viz 0.9s ease-in-out infinite alternate; }
.music-viz i:nth-child(2) { animation-delay: 0.15s; }
.music-viz i:nth-child(3) { animation-delay: 0.3s; }
.music-viz i:nth-child(4) { animation-delay: 0.45s; }
.music-viz i:nth-child(5) { animation-delay: 0.1s; }
.music-viz i:nth-child(6) { animation-delay: 0.35s; }
.music-viz i:nth-child(7) { animation-delay: 0.25s; }
.music-viz i:nth-child(8) { animation-delay: 0.5s; }
@keyframes viz { from { height: 15%; } to { height: 100%; } }
.music-list { border-top: 1px dashed var(--line); padding-top: 10px; max-height: 168px; overflow-y: auto; }
.music-list li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 8px;
  border-radius: 9px;
  font-size: 12.5px;
  color: var(--ink-soft);
  cursor: pointer;
  transition: all 0.2s;
}
.music-list li:hover { background: var(--bg-soft); color: var(--ink); }
.music-list li.cur { color: var(--apricot-deep); font-weight: 700; background: var(--apricot-mist); }
.music-list li .no {
  font-family: var(--font-en);
  font-size: 10px;
  width: 16px;
  text-align: center;
  opacity: 0.7;
}
.music-list li .dur { margin-left: auto; font-family: var(--font-en); font-size: 10px; opacity: 0.7; }

/* 公告 */
.notice-body { font-size: 13px; color: var(--ink-soft); line-height: 2; }
.notice-body .hl { color: var(--apricot-deep); font-weight: 700; }
.notice-body blockquote {
  border-left: 3px solid var(--apricot);
  padding: 4px 12px;
  background: var(--apricot-mist);
  border-radius: 0 8px 8px 0;
  margin: 10px 0;
  color: var(--ink);
  font-size: 12.5px;
}

/* 标签云 */
.tag-cloud { display: flex; flex-wrap: wrap; gap: 9px; }
.tag-cloud a {
  font-size: 12px;
  padding: 5px 13px;
  border-radius: 99px;
  border: 1px dashed var(--line);
  color: var(--ink-soft);
  transition: all 0.25s;
}
.tag-cloud a:hover {
  border-style: solid;
  border-color: var(--apricot);
  color: var(--apricot-deep);
  background: var(--apricot-mist);
  transform: translateY(-2px);
}
.tag-cloud a .n { font-size: 10px; opacity: 0.6; margin-left: 3px; }

/* ---------- 页脚 ---------- */
.footer {
  border-top: 1px dashed var(--line);
  background: var(--bg-soft);
  padding: 48px 0 26px;
  margin-top: 40px;
  position: relative;
}
.footer::before {
  content: "✦ · ✧ · ✦ · ✧ · ✦";
  position: absolute;
  top: -12px; left: 50%;
  transform: translateX(-50%);
  background: var(--bg-soft);
  padding: 0 16px;
  color: var(--star);
  font-size: 11px;
  letter-spacing: 6px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 36px;
}
.footer h4 {
  font-family: var(--font-serif);
  font-size: 15px;
  font-weight: 900;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.footer h4::before { content: ""; width: 14px; height: 2px; background: var(--apricot); border-radius: 2px; }
.footer p, .footer li { font-size: 12.5px; color: var(--ink-soft); line-height: 2.1; }
.footer li a:hover { color: var(--apricot-deep); }
.footer .f-brand {
  font-family: var(--font-serif);
  font-size: 19px;
  font-weight: 900;
  margin-bottom: 12px;
}
.footer .f-brand span { color: var(--apricot-deep); }
.footer .f-verse {
  font-size: 12px;
  color: var(--ink-soft);
  line-height: 2.1;
  border-left: 2px solid var(--blue);
  padding-left: 12px;
  margin-top: 14px;
}
.footer-bottom {
  border-top: 1px solid var(--line);
  padding-top: 22px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  color: var(--ink-soft);
}
.footer-bottom .stats { display: flex; gap: 18px; font-family: var(--font-en); }
.footer-bottom .stats b { color: var(--apricot-deep); font-weight: 600; }

/* ---------- 页面通用页头（子页面） ---------- */
.page-hero {
  margin-top: var(--nav-h);
  padding: 72px 0 56px;
  text-align: center;
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(ellipse 60% 80% at 50% -10%, var(--blue-mist), transparent 70%),
    var(--bg);
  border-bottom: 1px dashed var(--line);
}
.page-hero .jp-title {
  font-family: var(--font-serif);
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 900;
  line-height: 1.4;
}
.page-hero .jp-title .accent { color: var(--apricot-deep); }
.page-hero .en-title {
  font-family: var(--font-en);
  font-size: 12px;
  letter-spacing: 5px;
  color: var(--ink-soft);
  text-transform: uppercase;
  margin-top: 12px;
}
.page-hero .deco-line {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 20px;
  color: var(--star);
  font-size: 12px;
}
.page-hero .deco-line::before, .page-hero .deco-line::after {
  content: "";
  width: 60px; height: 1px;
  background: linear-gradient(90deg, transparent, var(--star));
}
.page-hero .deco-line::after { background: linear-gradient(90deg, var(--star), transparent); }

/* ---------- 归档页 ---------- */
.archive-timeline { position: relative; padding: 10px 0 30px; }
.archive-timeline::before {
  content: "";
  position: absolute;
  left: 7px; top: 12px; bottom: 0;
  width: 2px;
  background: repeating-linear-gradient(180deg, var(--line) 0 6px, transparent 6px 12px);
}
.archive-year {
  font-family: var(--font-serif);
  font-size: 22px;
  font-weight: 900;
  margin: 34px 0 18px;
  display: flex;
  align-items: center;
  gap: 12px;
  position: relative;
}
.archive-year::before {
  content: "";
  width: 16px; height: 16px;
  border-radius: 50%;
  background: var(--card);
  border: 3px solid var(--apricot);
  flex-shrink: 0;
  position: relative;
  z-index: 1;
  box-shadow: 0 0 0 4px var(--bg);
}
.archive-year .count {
  font-family: var(--font-en);
  font-size: 12px;
  color: var(--ink-soft);
  font-weight: 400;
}
.archive-item {
  display: flex;
  gap: 20px;
  padding: 14px 0 14px 32px;
  position: relative;
  align-items: baseline;
}
.archive-item::before {
  content: "✦";
  position: absolute;
  left: 0; top: 18px;
  color: var(--blue);
  font-size: 12px;
}
.archive-item .date {
  font-family: var(--font-en);
  font-size: 12.5px;
  color: var(--ink-soft);
  flex-shrink: 0;
  width: 52px;
}
.archive-item .title { font-weight: 500; }
.archive-item .title:hover { color: var(--apricot-deep); }
.archive-item .cat { margin-left: auto; flex-shrink: 0; }

/* ---------- 分类 / 标签页 ---------- */
.cat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 22px; }
.cat-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px;
  display: flex;
  align-items: center;
  gap: 18px;
  box-shadow: var(--shadow);
  transition: all 0.3s;
  position: relative;
  overflow: hidden;
}
.cat-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-hover); border-color: var(--blue); }
.cat-card .icon {
  width: 56px; height: 56px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  font-size: 24px;
  flex-shrink: 0;
  color: #fff;
}
.cat-card h3 { font-family: var(--font-serif); font-size: 17px; font-weight: 900; }
.cat-card .sub { font-size: 12px; color: var(--ink-soft); margin-top: 3px; }
.cat-card .num {
  margin-left: auto;
  font-family: var(--font-en);
  font-size: 22px;
  font-weight: 600;
  color: var(--blue);
}
.cat-card::after {
  content: "✧";
  position: absolute;
  right: -8px; bottom: -14px;
  font-size: 44px;
  color: var(--blue-mist);
  pointer-events: none;
}

/* ---------- 文章详情页 ---------- */
.article-hero {
  margin-top: var(--nav-h);
  position: relative;
  height: 420px;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  background: #22314C;
}
.article-hero img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.article-hero::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(0deg, var(--bg) 0%, rgba(20,30,52,0.35) 45%, rgba(20,30,52,0.15) 100%);
}
.article-hero .head { position: relative; z-index: 2; padding-bottom: 40px; width: 100%; }
.article-hero .chips { display: flex; gap: 8px; margin-bottom: 16px; flex-wrap: wrap; }
.article-hero h1 {
  font-family: var(--font-serif);
  font-size: clamp(24px, 3.4vw, 36px);
  font-weight: 900;
  line-height: 1.5;
  max-width: 800px;
  text-shadow: 0 2px 20px rgba(20,30,52,0.4);
}
.article-hero .meta {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin-top: 16px;
  font-size: 13px;
  color: var(--ink-soft);
}
.article-hero .meta span { display: inline-flex; align-items: center; gap: 6px; }
.article-hero .meta svg { width: 14px; height: 14px; }

.article-layout {
  display: grid;
  grid-template-columns: 1fr 240px;
  gap: 40px;
  align-items: start;
  padding: 40px 0 60px;
}
.article-body {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 40px 44px;
  box-shadow: var(--shadow);
  font-size: 15px;
}
.article-body > p { margin-bottom: 20px; }
.article-body h2 {
  font-family: var(--font-serif);
  font-size: 22px;
  font-weight: 900;
  margin: 42px 0 18px;
  padding-left: 16px;
  border-left: 4px solid var(--apricot);
  line-height: 1.5;
}
.article-body h3 {
  font-family: var(--font-serif);
  font-size: 17.5px;
  font-weight: 700;
  margin: 30px 0 14px;
  display: flex;
  align-items: center;
  gap: 9px;
}
.article-body h3::before { content: "❖"; color: var(--blue); font-size: 13px; }
.article-body blockquote {
  margin: 24px 0;
  padding: 18px 22px;
  background: var(--blue-mist);
  border-left: 4px solid var(--blue);
  border-radius: 0 12px 12px 0;
  color: var(--ink);
  font-size: 14px;
  position: relative;
}
.article-body blockquote::before {
  content: "「";
  position: absolute;
  top: -2px; left: 8px;
  font-size: 34px;
  color: var(--blue);
  opacity: 0.35;
  font-family: var(--font-serif);
}
.article-body blockquote p { margin: 0; position: relative; z-index: 1; }
.article-body blockquote .src { display: block; margin-top: 8px; font-size: 12px; color: var(--ink-soft); }
.article-body pre {
  background: #2A3550;
  color: #D8E2F0;
  border-radius: 12px;
  padding: 20px 22px;
  overflow-x: auto;
  font-size: 13px;
  line-height: 1.8;
  margin: 24px 0;
  font-family: "SF Mono", "JetBrains Mono", Consolas, monospace;
  position: relative;
}
.article-body pre::after {
  content: "♪";
  position: absolute;
  top: 10px; right: 14px;
  color: var(--butter);
  opacity: 0.6;
}
.article-body code {
  font-family: "SF Mono", "JetBrains Mono", Consolas, monospace;
  background: var(--butter-mist);
  color: #A87B2E;
  padding: 2px 7px;
  border-radius: 6px;
  font-size: 0.88em;
}
.article-body pre code { background: none; color: inherit; padding: 0; }
.article-body ul:not(.nav):not(.music-list) { margin: 16px 0 22px; }
.article-body ul:not(.nav):not(.music-list) li {
  padding-left: 24px;
  position: relative;
  margin-bottom: 8px;
}
.article-body ul:not(.nav):not(.music-list) li::before {
  content: "✦";
  position: absolute;
  left: 2px;
  color: var(--star);
  font-size: 11px;
  top: 5px;
}
.article-body ol { margin: 16px 0 22px; counter-reset: o; }
.article-body ol li { padding-left: 30px; position: relative; margin-bottom: 8px; counter-increment: o; }
.article-body ol li::before {
  content: counter(o);
  position: absolute;
  left: 0; top: 3px;
  width: 19px; height: 19px;
  border-radius: 50%;
  background: var(--apricot);
  color: #fff;
  font-size: 11px;
  font-family: var(--font-en);
  display: grid;
  place-items: center;
  font-weight: 600;
}
.article-body table { width: 100%; border-collapse: collapse; margin: 24px 0; font-size: 13.5px; }
.article-body th {
  background: var(--blue-mist);
  color: var(--blue-deep);
  padding: 10px 14px;
  text-align: left;
  font-weight: 700;
}
.article-body td { padding: 10px 14px; border-bottom: 1px solid var(--line); }
.article-body tr:hover td { background: var(--bg-soft); }
.article-body hr {
  border: none;
  margin: 40px auto;
  width: 60%;
  height: 12px;
  background: radial-gradient(circle, var(--star) 40%, transparent 41%) 0 0/12px 12px repeat-x;
  opacity: 0.55;
}
.article-body .img-note { text-align: center; font-size: 12px; color: var(--ink-soft); margin: -10px 0 26px; }
.article-body strong { color: var(--apricot-deep); }
.article-body a.dl {
  color: var(--blue-deep);
  border-bottom: 1px dashed var(--blue);
}
.article-body a.dl:hover { color: var(--apricot-deep); border-color: var(--apricot); }

/* 文章底部 */
.article-foot { margin-top: 36px; }
.post-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 30px;
}
.post-nav a {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px 22px;
  transition: all 0.3s;
  box-shadow: var(--shadow);
}
.post-nav a:hover { border-color: var(--apricot); transform: translateY(-4px); box-shadow: var(--shadow-hover); }
.post-nav .lbl { font-size: 11px; color: var(--ink-soft); letter-spacing: 2px; margin-bottom: 6px; display: flex; align-items: center; gap: 5px; }
.post-nav .t { font-weight: 700; font-family: var(--font-serif); font-size: 14.5px; display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; }
.post-nav a:last-child { text-align: right; }
.post-nav a:last-child .lbl { justify-content: flex-end; }

/* 版权卡 */
.copyright-card {
  background: linear-gradient(120deg, var(--apricot-mist), var(--butter-mist));
  border: 1px dashed var(--apricot);
  border-radius: var(--radius);
  padding: 20px 24px;
  font-size: 12.5px;
  color: var(--ink-soft);
  line-height: 2;
}
.copyright-card b { color: var(--apricot-deep); }

/* 评论区 */
.comments { margin-top: 36px; }
.comment-input-box {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: var(--shadow);
  margin-bottom: 26px;
}
.comment-input-box textarea {
  width: 100%;
  min-height: 96px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--bg-soft);
  padding: 13px 15px;
  font-family: inherit;
  font-size: 13.5px;
  color: var(--ink);
  resize: vertical;
  outline: none;
  transition: border-color 0.25s;
}
.comment-input-box textarea:focus { border-color: var(--apricot); }
.comment-input-box .row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 12px;
  font-size: 12px;
  color: var(--ink-soft);
}
.comment-item {
  display: flex;
  gap: 15px;
  padding: 20px 0;
  border-bottom: 1px dashed var(--line);
}
.comment-item:last-child { border-bottom: none; }
.comment-item .avatar {
  width: 44px; height: 44px;
  border-radius: 50%;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  font-size: 20px;
  border: 2px solid var(--card);
  box-shadow: 0 0 0 1px var(--line);
}
.comment-item .c-head { display: flex; align-items: baseline; gap: 10px; margin-bottom: 4px; flex-wrap: wrap; }
.comment-item .c-name { font-weight: 700; font-size: 14px; }
.comment-item .c-tag {
  font-size: 10px;
  background: var(--blue-mist);
  color: var(--blue-deep);
  padding: 2px 8px;
  border-radius: 99px;
  font-weight: 700;
}
.comment-item .c-time { font-size: 11px; color: var(--ink-soft); font-family: var(--font-en); }
.comment-item .c-text { font-size: 13.5px; color: var(--ink-soft); line-height: 1.9; }
.comment-item .c-reply {
  margin-top: 10px;
  background: var(--bg-soft);
  border-radius: 10px;
  padding: 10px 14px;
  font-size: 12.5px;
  color: var(--ink-soft);
  border-left: 3px solid var(--blue);
}
.comment-item .c-reply b { color: var(--blue-deep); }

/* 右侧浮动目录 */
.toc-widget {
  position: sticky;
  top: calc(var(--nav-h) + 24px);
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow);
  max-height: calc(100vh - var(--nav-h) - 60px);
  overflow-y: auto;
}
.toc-widget .t { font-family: var(--font-serif); font-weight: 900; font-size: 14px; margin-bottom: 14px; display: flex; align-items: center; gap: 8px; }
.toc-widget .t::before { content: "❖"; color: var(--apricot); font-size: 11px; }
.toc-widget a {
  display: block;
  font-size: 12.5px;
  color: var(--ink-soft);
  padding: 6px 10px;
  border-radius: 8px;
  border-left: 2px transparent;
  transition: all 0.2s;
  line-height: 1.6;
}
.toc-widget a:hover { color: var(--apricot-deep); background: var(--apricot-mist); }
.toc-widget a.active {
  color: var(--blue-deep);
  background: var(--blue-mist);
  border-left-color: var(--blue);
  font-weight: 700;
}
.toc-widget a.lv3 { padding-left: 24px; font-size: 12px; }
.toc-progress {
  height: 3px;
  background: var(--line);
  border-radius: 99px;
  margin-bottom: 16px;
  overflow: hidden;
}
.toc-progress i {
  display: block;
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--blue), var(--apricot));
  border-radius: 99px;
}

/* 移动端目录按钮 */
.toc-fab {
  display: none;
  position: fixed;
  right: 18px; bottom: 96px;
  z-index: 90;
  width: 44px; height: 44px;
  border-radius: 50%;
  background: var(--card);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  place-items: center;
  color: var(--ink-soft);
}
.toc-fab svg { width: 18px; height: 18px; }

/* ---------- 留言板 ---------- */
.msg-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 26px; }
.msg-wall { display: grid; gap: 18px; }
.msg-note {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 18px 20px;
  box-shadow: var(--shadow);
  position: relative;
  transition: all 0.3s;
}
.msg-note:hover { transform: rotate(-0.5deg) translateY(-3px); box-shadow: var(--shadow-hover); border-color: var(--apricot); }
.msg-note::before {
  content: "";
  position: absolute;
  top: -8px; left: 50%;
  transform: translateX(-50%) rotate(-4deg);
  width: 44px; height: 14px;
  background: var(--butter);
  opacity: 0.65;
  border-radius: 2px;
}
.msg-note .m-head { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.msg-note .m-avatar { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; font-size: 16px; }
.msg-note .m-name { font-weight: 700; font-size: 13.5px; }
.msg-note .m-time { font-size: 10.5px; color: var(--ink-soft); font-family: var(--font-en); margin-left: auto; }
.msg-note .m-text { font-size: 13px; color: var(--ink-soft); line-height: 1.9; }

/* ---------- 友链 ---------- */
.link-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 20px; }
.link-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
  display: flex;
  gap: 15px;
  align-items: center;
  box-shadow: var(--shadow);
  transition: all 0.3s;
}
.link-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-hover); border-color: var(--blue); }
.link-card .l-avatar {
  width: 52px; height: 52px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  font-size: 23px;
  flex-shrink: 0;
  color: #fff;
}
.link-card .l-name { font-weight: 700; font-size: 14.5px; display: flex; align-items: center; gap: 6px; }
.link-card .l-desc { font-size: 12px; color: var(--ink-soft); margin-top: 3px; line-height: 1.6; }
.link-card .l-arrow { margin-left: auto; color: var(--line); transition: all 0.3s; }
.link-card:hover .l-arrow { color: var(--apricot); transform: translateX(3px); }

/* ---------- 关于页 ---------- */
.about-grid { display: grid; grid-template-columns: 1.15fr 1fr; gap: 36px; align-items: start; }
.about-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 36px;
  box-shadow: var(--shadow);
}
.about-card h2 {
  font-family: var(--font-serif);
  font-size: 22px;
  font-weight: 900;
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.about-card h2 .jp { font-size: 12px; color: var(--ink-soft); font-family: var(--font-round); font-weight: 400; }
.about-card p { margin-bottom: 15px; color: var(--ink-soft); font-size: 14px; }
.about-card p b { color: var(--apricot-deep); }
.about-facts { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 20px; }
.fact {
  background: var(--bg-soft);
  border: 1px dashed var(--line);
  border-radius: 12px;
  padding: 13px 15px;
}
.fact .k { font-size: 11px; color: var(--ink-soft); letter-spacing: 1px; }
.fact .v { font-weight: 700; font-size: 14px; margin-top: 3px; }
.about-art {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  position: relative;
}
.about-art img { width: 100%; }
.about-art .cap {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  padding: 30px 22px 18px;
  background: linear-gradient(0deg, rgba(25,32,50,0.85), transparent);
  color: #FBF7EC;
  font-family: var(--font-serif);
  font-size: 13px;
  letter-spacing: 1px;
}
.timeline-fav { margin-top: 26px; }
.timeline-fav .yr { font-family: var(--font-serif); font-weight: 900; font-size: 16px; margin-bottom: 10px; display: flex; gap: 10px; align-items: center; }
.timeline-fav .yr::before { content: "☄"; color: var(--star); }
.timeline-fav li {
  font-size: 13px;
  color: var(--ink-soft);
  padding: 6px 0 6px 18px;
  border-left: 2px dashed var(--line);
  margin-left: 5px;
  position: relative;
}
.timeline-fav li::before { content: "♪"; position: absolute; left: -6px; top: 6px; color: var(--apricot); font-size: 11px; }

/* ---------- 返回顶部 ---------- */
.back-top {
  position: fixed;
  right: 22px; bottom: 26px;
  z-index: 90;
  width: 46px; height: 46px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--apricot), var(--apricot-deep));
  color: #fff;
  display: grid;
  place-items: center;
  box-shadow: 0 8px 22px rgba(196, 118, 63, 0.4);
  opacity: 0;
  transform: translateY(16px) scale(0.85);
  transition: all 0.35s;
  pointer-events: none;
}
.back-top.show { opacity: 1; transform: none; pointer-events: auto; }
.back-top:hover { transform: translateY(-4px); }
.back-top svg { width: 18px; height: 18px; }
.back-top::after {
  content: "";
  position: absolute;
  inset: -5px;
  border-radius: 50%;
  border: 1.5px dashed var(--apricot);
  opacity: 0.5;
  animation: spinRing 12s linear infinite;
}

/* ---------- 左下小兔挂件 ---------- */
.bunny-dock {
  position: fixed;
  left: 20px; bottom: 22px;
  z-index: 90;
  display: flex;
  align-items: flex-end;
  gap: 10px;
}
.bunny-figure {
  width: 74px;
  cursor: pointer;
  filter: drop-shadow(0 6px 14px rgba(60, 60, 90, 0.22));
  transition: transform 0.3s;
  animation: bunnyFloat 3.4s ease-in-out infinite;
}
.bunny-figure:hover { transform: scale(1.08) rotate(-4deg); }
@keyframes bunnyFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-7px); }
}
.bunny-bubble {
  background: var(--card);
  border: 1.5px solid var(--apricot);
  border-radius: 14px 14px 14px 3px;
  padding: 9px 14px;
  font-size: 12px;
  color: var(--ink);
  box-shadow: var(--shadow);
  max-width: 190px;
  line-height: 1.7;
  position: relative;
  margin-bottom: 26px;
  opacity: 0;
  transform: translateX(-8px);
  transition: all 0.35s;
}
.bunny-bubble.show { opacity: 1; transform: none; }

/* ---------- 点击星星粒子 ---------- */
.click-star {
  position: fixed;
  z-index: 999;
  pointer-events: none;
  font-size: 13px;
  animation: starPop 0.9s ease-out forwards;
}
@keyframes starPop {
  0% { opacity: 1; transform: translate(0, 0) scale(0.4) rotate(0); }
  100% { opacity: 0; transform: translate(var(--dx), var(--dy)) scale(1.25) rotate(var(--rot)); }
}

/* ---------- 滚动显现 ---------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.2, 0.8, 0.2, 1); }
.reveal.visible { opacity: 1; transform: none; }

/* ---------- 搜索浮层 ---------- */
.search-mask {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(20, 26, 42, 0.55);
  backdrop-filter: blur(6px);
  display: grid;
  place-items: start center;
  padding-top: 14vh;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
}
.search-mask.open { opacity: 1; pointer-events: auto; }
.search-box {
  width: min(560px, 90vw);
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: 0 24px 64px rgba(0,0,0,0.3);
  overflow: hidden;
  transform: translateY(-14px);
  transition: transform 0.3s;
}
.search-mask.open .search-box { transform: none; }
.search-box .s-head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--line);
}
.search-box .s-head svg { width: 17px; height: 17px; color: var(--ink-soft); flex-shrink: 0; }
.search-box input {
  flex: 1;
  border: none;
  outline: none;
  background: none;
  font-size: 15px;
  color: var(--ink);
  font-family: inherit;
}
.search-box .s-close { font-size: 11px; color: var(--ink-soft); border: 1px solid var(--line); border-radius: 6px; padding: 2px 8px; font-family: var(--font-en); }
.search-results { padding: 10px; max-height: 46vh; overflow-y: auto; }
.search-results .r-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 14px;
  border-radius: 11px;
  transition: background 0.2s;
}
.search-results .r-item:hover { background: var(--bg-soft); }
.search-results .r-item .r-ico { color: var(--apricot); font-size: 13px; }
.search-results .r-item .r-t { font-size: 13.5px; font-weight: 500; }
.search-results .r-item .r-d { font-size: 11.5px; color: var(--ink-soft); margin-left: auto; flex-shrink: 0; }
.search-results .empty { text-align: center; color: var(--ink-soft); font-size: 13px; padding: 30px 0; }
.search-results .empty .face { font-size: 30px; display: block; margin-bottom: 8px; }

/* ---------- 响应式 ---------- */
@media (max-width: 1024px) {
  .layout { grid-template-columns: 1fr; }
  .sidebar { position: static; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
  .article-layout { grid-template-columns: 1fr; }
  .toc-widget { display: none; }
  .toc-fab { display: grid; }
  .about-grid, .msg-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
  :root { --nav-h: 58px; }
  .nav-menu { display: none; }
  .nav-burger { display: grid !important; }
  .post-card { grid-template-columns: 1fr; }
  .post-card .thumb { min-height: 170px; }
  .hero { min-height: 480px; }
  .article-body { padding: 26px 22px; }
  .article-hero { height: 340px; }
  .post-nav { grid-template-columns: 1fr; }
  .post-nav a:last-child { text-align: left; }
  .post-nav a:last-child .lbl { justify-content: flex-start; }
  .footer-grid { grid-template-columns: 1fr; gap: 26px; }
  .bunny-dock { left: 12px; bottom: 14px; transform: scale(0.85); transform-origin: left bottom; }
  .section { padding: 44px 0 8px; }
  .feature-card .content { padding: 24px; }
  .back-top { right: 14px; bottom: 18px; }
  .toc-fab { right: 14px; bottom: 84px; }
}

/* 减少动效偏好 */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01s !important; transition-duration: 0.01s !important; }
}
