/* ==========================================================
   亮色主题 + 顶部「粉蓝渐变海面」头图
   该文件在模板自带 <style> 之后加载，用于覆盖深色配色
   ========================================================== */

:root {
  --ink:        #17293f;   /* 主文字 */
  --ink-soft:   #46617d;   /* 次文字 */
  --muted:      #6f8199;   /* 弱化文字 */
  --line:       rgba(120, 150, 190, .30);
  --card:       #ffffff;
  --bg:         #f4f7fc;
  --accent:     #2f6fed;   /* 蓝 */
  --accent-2:   #ff7bab;   /* 粉 */
  --shadow:     0 10px 28px rgba(60, 105, 170, .12);
  --shadow-lg:  0 18px 40px rgba(60, 105, 170, .18);
}

/* ---------- 页面底色 ---------- */
html, body {
  background: var(--bg);
}

body {
  position: relative;
  color: var(--ink);
  background:
    radial-gradient(1200px 520px at 12% -8%, rgba(255, 196, 220, .35), transparent 60%),
    radial-gradient(1100px 480px at 88% -12%, rgba(168, 208, 255, .40), transparent 62%),
    linear-gradient(180deg, #fbfdff 0%, var(--bg) 42%, #eef4fb 100%);
  background-attachment: fixed;
}

/* 鼠标氛围光：改成粉蓝调 */
body::after {
  background: radial-gradient(
    760px circle at var(--mx, 50vw) var(--my, 50vh),
    rgba(255, 168, 200, .14),
    transparent 46%
  ) !important;
}

/* ---------- 顶部海面头图 ---------- */
.sea-band {
  position: relative;
  z-index: 0;
  height: 260px;
  overflow: hidden;
  pointer-events: none;
  background:
    radial-gradient(200px 200px at 20% 30%, rgba(255, 244, 248, .95), rgba(255, 244, 248, 0) 70%),
    radial-gradient(120% 90% at 8% 4%, rgba(255, 186, 214, .95), rgba(255, 186, 214, 0) 58%),
    radial-gradient(95% 85% at 86% -6%, rgba(176, 210, 255, .92), rgba(176, 210, 255, 0) 62%),
    linear-gradient(180deg, #ffe6f1 0%, #ffd3e6 24%, #e6dcf7 44%, #bcd8fb 66%, #8fbdf2 100%);
  -webkit-mask-image: linear-gradient(180deg, #000 78%, transparent 100%);
          mask-image: linear-gradient(180deg, #000 78%, transparent 100%);
}

body.is-home .sea-band { height: 360px; }

/* 海面：从地平线往下 44% 开始 */
.sea-band::before {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 44%;
  background:
    repeating-linear-gradient(180deg,
      rgba(255, 255, 255, .50) 0px,
      rgba(255, 255, 255, .50) 1px,
      rgba(255, 255, 255, 0) 1px,
      rgba(255, 255, 255, 0) 9px),
    radial-gradient(70% 130% at 26% 0%, rgba(255, 255, 255, .55), rgba(255, 255, 255, 0) 62%),
    linear-gradient(180deg, #aed6f9 0%, #82b7ef 40%, #4f8fdd 100%);
  background-size: 100% 100%, 100% 100%, 100% 100%;
  animation: sea-shimmer 7s linear infinite;
}

/* 地平线高光 + 水面反光带 */
.sea-band::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 46%;
  background:
    radial-gradient(14% 90% at 24% 0%, rgba(255, 255, 255, .92), rgba(255, 255, 255, 0) 72%),
    radial-gradient(10% 70% at 62% 0%, rgba(255, 255, 255, .55), rgba(255, 255, 255, 0) 72%),
    linear-gradient(180deg, rgba(255, 255, 255, .85) 0%, rgba(255, 255, 255, 0) 6%);
  filter: blur(3px);
  opacity: .9;
  animation: sea-glint 9s ease-in-out infinite alternate;
}

@keyframes sea-shimmer {
  0%   { background-position: 0 0, 0 0, 0 0; }
  100% { background-position: 0 -180px, 0 0, 0 0; }
}

@keyframes sea-glint {
  0%   { transform: translateY(0) scaleX(1);        opacity: .75; }
  50%  { transform: translateY(-4px) scaleX(1.04);  opacity: .95; }
  100% { transform: translateY(2px) scaleX(.98);    opacity: .8; }
}

@media (prefers-reduced-motion: reduce) {
  .sea-band::before, .sea-band::after { animation: none; }
}

@media (max-width: 640px) {
  .sea-band { height: 170px; }
  body.is-home .sea-band { height: 230px; }
}

/* ---------- 导航栏：白玻璃 ---------- */
.navbar {
  background: rgba(255, 255, 255, .78) !important;
  border-bottom: 1px solid var(--line) !important;
  backdrop-filter: blur(14px) saturate(1.2);
  box-shadow: 0 4px 20px rgba(70, 110, 170, .08);
}

.logo a { color: var(--ink) !important; }
.logo a:hover { color: var(--accent) !important; }

.nav-links a { color: var(--ink-soft) !important; }
.nav-links a:hover { color: var(--accent) !important; background-size: 100% 2px; }

.avatar-btn {
  border-color: rgba(255, 255, 255, .9) !important;
  box-shadow: 0 3px 12px rgba(60, 105, 170, .22);
  background: #fff;
}
.avatar-btn:hover { border-color: var(--accent-2) !important; }

/* ---------- 正文文字 ---------- */
a { color: var(--accent); }
a:hover { color: var(--accent-2); }

.hero h1, .section-title, .article-title,
.article-content h2, .article-content h3,
.profile-header h1, .auth-header h1,
.article-content strong { color: var(--ink) !important; }

.hero p, .back-link, .article-meta, .footer, .hint,
.form-group label, .form-group .hint,
.user-info .username, .user-id, .username,
.comment-time, .char-count, .loading, .no-comments,
.no-notifications, .title-preview-label { color: var(--muted) !important; }

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

.section-title { border-bottom-color: var(--line) !important; }

.article-content { color: var(--ink-soft) !important; }
.article-content p, .article-content li { color: var(--ink-soft); }
.article-header { border-bottom-color: var(--line) !important; }
.article-content h2 { border-bottom-color: var(--line) !important; }

.article-content blockquote {
  background: #eff6ff !important;
  border-left-color: var(--accent) !important;
  color: var(--ink-soft) !important;
}

.article-content code {
  background: #eef3fb !important;
  color: #1f5bc4 !important;
}

.article-content pre {
  background: #f7fafd !important;
  border-color: var(--line) !important;
}
.article-content pre code { color: var(--ink) !important; }

.article-content table { background: var(--card) !important; color: var(--ink-soft); }
.article-content th, .article-content td { border-color: var(--line) !important; }
.article-content thead th { background: #eef4fd !important; color: var(--ink) !important; }
.article-content tbody tr { background: var(--card) !important; }
.article-content tbody tr:nth-child(even) { background: #f7fafd !important; }
.article-content tbody tr:hover { background: #eef4fd !important; }
.article-content td:last-child { color: var(--accent) !important; }

.footer { border-top-color: var(--line) !important; }

/* ---------- 卡片 ---------- */
.post {
  border-color: var(--line) !important;
  box-shadow: var(--shadow) !important;
}
.post:hover {
  border-color: rgba(47, 111, 237, .35) !important;
  box-shadow: var(--shadow-lg) !important;
}

.comment-item,
.notification-item,
.reply-form,
.title-preview {
  background: var(--card) !important;
  border-color: var(--line) !important;
}
.notification-item.unread {
  background: #f2f8ff !important;
  border-left-color: var(--accent) !important;
}
.comment-username, .comments-title, .card-title { color: var(--ink) !important; }
.comment-content { color: var(--ink-soft) !important; }
.comment-actions-bar .comment-action-btn { color: var(--muted); }
.comments-section { border-top-color: var(--line) !important; }

.avatar { background: linear-gradient(135deg, #ffb3cf, #7fb2f0) !important;
          box-shadow: 0 10px 26px rgba(255, 150, 190, .35) !important; }

/* ---------- 表单 ---------- */
.form-group input,
.form-group textarea,
#comment-content,
.reply-form textarea,
.color-picker-group input[type="text"],
#newBio, #newTitle, #newDisplayName {
  background: #fff !important;
  border-color: var(--line) !important;
  color: var(--ink) !important;
}
.form-group input::placeholder,
.form-group textarea::placeholder,
#comment-content::placeholder { color: #9aabc0 !important; }

.form-group input:focus,
.form-group textarea:focus,
#comment-content:focus,
.reply-form textarea:focus {
  border-color: var(--accent) !important;
  box-shadow: 0 0 0 3px rgba(47, 111, 237, .12) !important;
}

/* ---------- 按钮 ---------- */
.submit-btn,
.save-btn,
.submit-comment-btn,
.reply-submit-btn,
.register-btn {
  background: linear-gradient(135deg, #ff9dc0, #6aa8f0) !important;
  color: #fff !important;
  border: none !important;
  box-shadow: 0 6px 18px rgba(120, 150, 220, .30);
  background-image: linear-gradient(135deg, #ff9dc0, #6aa8f0) !important;
}
.submit-btn:hover,
.save-btn:hover,
.submit-comment-btn:hover,
.reply-submit-btn:hover,
.register-btn:hover {
  box-shadow: 0 10px 24px rgba(120, 150, 220, .40);
  transform: translateY(-2px);
}

.reply-cancel-btn {
  background: #eef3fb !important;
  color: var(--ink-soft) !important;
}

.logout-btn {
  background: #fff0f5 !important;
  border-color: rgba(255, 123, 171, .45) !important;
  color: #d94f7f !important;
}
.logout-btn:hover { background: #ffe4ee !important; }

/* ---------- 标签/徽章 ---------- */
.post-meta .tag,
.article-meta .tag,
.comment-user-role {
  backdrop-filter: blur(4px);
}
.article-meta .tag {
  background: rgba(47, 111, 237, .10) !important;
  color: var(--accent) !important;
  border-color: rgba(47, 111, 237, .28) !important;
}
.comment-user-role {
  background: rgba(255, 176, 70, .18) !important;
  color: #b06f00 !important;
  border-color: rgba(255, 176, 70, .45) !important;
}

/* ---------- 提示框 ---------- */
.alert-success {
  background: #eefaf3 !important;
  border-color: rgba(45, 180, 120, .35) !important;
  color: #17845a !important;
}
.alert-error {
  background: #fff0f4 !important;
  border-color: rgba(255, 123, 171, .45) !important;
  color: #d94f7f !important;
}
.login-prompt {
  background: #f2f8ff !important;
  border: 1px solid var(--line);
}
.login-prompt a { color: var(--accent) !important; }

/* ---------- 登录/资料页卡片 ---------- */
.auth-card, .profile-card {
  background: rgba(255, 255, 255, .92) !important;
  border-color: var(--line) !important;
  box-shadow: var(--shadow-lg);
  backdrop-filter: blur(12px);
}
.auth-header p, .display-name, .user-info .display-name { color: var(--ink) !important; }
.current-avatar { border-color: rgba(255, 255, 255, .95) !important;
                  box-shadow: 0 8px 24px rgba(255, 150, 190, .3); }
.bio {
  background: #f2f8ff !important;
  border-left-color: var(--accent) !important;
  color: var(--ink-soft) !important;
}
.role-badge {
  background: rgba(255, 196, 86, .22) !important;
  color: #a06a00 !important;
  border-color: rgba(255, 196, 86, .5) !important;
}
.unread-badge { background: var(--accent-2) !important; color: #fff; }

.form-section { border-bottom-color: var(--line) !important; }
.form-section h2 { color: var(--ink) !important; }
.title-preview { border: 1px dashed var(--line); }

/* ---------- 补充覆盖 ---------- */
.footer a { color: var(--accent) !important; }
.footer a:hover { color: var(--accent-2) !important; }
.auth-footer a { color: var(--accent) !important; }
.post:hover .post-content h2 { color: #ffd9e8 !important; }
.avatar-option.selected {
  border-color: var(--accent-2) !important;
  box-shadow: 0 0 0 4px rgba(255, 123, 171, .18) !important;
}
.preset-item.selected { border-color: var(--accent) !important; }
.article-content a { color: var(--accent); border-bottom: 1px solid rgba(47,111,237,.25); }
.article-content hr { border-color: var(--line); }
.navbar .avatar-btn { background: transparent !important; }

/* ==========================================================
   卡片比例统一（桌面 = 移动端观感）+ 淡蓝实心阴影
   ========================================================== */

:root {
  --shadow-solid:       8px 8px 0 #d3e5ff;
  --shadow-solid-hover: 11px 11px 0 #c2dbff;
  --shadow-solid-sm:    5px 5px 0 #e2eeff;
}

/* 文章列表：桌面两列、手机一列，卡片比例两边完全一致 */
.post-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
  margin-bottom: 26px;
}

@media (max-width: 780px) {
  .post-grid { grid-template-columns: 1fr; gap: 18px; }
}

/* 卡片本体：用固定宽高比代替固定高度，任何屏宽都保持手机端那个方形观感 */
.post {
  height: auto !important;
  aspect-ratio: 16 / 11;
  margin: 0 !important;
  border-radius: 18px !important;
  border: 1px solid rgba(47, 111, 237, .18) !important;
  box-shadow: var(--shadow-solid) !important;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}

.post:hover {
  transform: translate(-3px, -3px) !important;
  box-shadow: var(--shadow-solid-hover) !important;
  border-color: rgba(47, 111, 237, .34) !important;
}

/* 卡片内文字随卡片变小收紧一点 */
.post-content { padding: 20px 18px !important; }
.post-content h2 { font-size: 19px !important; line-height: 1.45; }
.post-summary { font-size: 13px !important; }
.post-meta { font-size: 12.5px !important; }

@media (max-width: 480px) {
  .post-content h2 { font-size: 18px !important; }
  .post-summary { font-size: 12.5px !important; }
}

/* 其他卡片：统一成同一套实心阴影（更小一号） */
.comment-item,
.auth-card,
.profile-card,
.notification-item,
.login-prompt {
  box-shadow: var(--shadow-solid-sm) !important;
  border-radius: 16px !important;
  border: 1px solid rgba(47, 111, 237, .16) !important;
}

.auth-card, .profile-card { border-radius: 20px !important; }

.comment-item:hover { box-shadow: var(--shadow-solid) !important; }

/* hero 卡片也让阴影统一 */
.hero {
  box-shadow: var(--shadow-solid) !important;
  border-radius: 20px !important;
  border: 1px solid rgba(47, 111, 237, .16) !important;
}

/* ==========================================================
   移动端导航栏：单行不换行
   ========================================================== */
@media (max-width: 680px) {
  .navbar {
    padding: 8px 10px !important;
  }

  .navbar-inner {
    padding: 7px 10px !important;
    gap: 8px;
    flex-wrap: nowrap !important;
    align-items: center;
  }

  .nav-left {
    gap: 8px !important;
    min-width: 0;
    flex: 1 1 auto;
  }

  .avatar-btn {
    width: 28px !important;
    height: 28px !important;
    flex: 0 0 auto;
  }

  .logo { min-width: 0; }
  .logo a {
    font-size: 15px !important;
    white-space: nowrap;
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 34vw;
  }

  .nav-links {
    display: flex;
    align-items: center;
    gap: 2px;
    flex: 0 0 auto;
  }

  .nav-links a {
    margin-left: 0 !important;
    padding: 4px 6px !important;
    font-size: 12.5px !important;
    line-height: 1.4;
    white-space: nowrap !important;
    background-image: none !important;
    max-width: 22vw;
    overflow: hidden;
    text-overflow: ellipsis;
    text-align: center;
  }

  .nav-links a:hover { background-size: 0% 0 !important; }

  .nav-links .register-btn {
    padding: 5px 9px !important;
    font-size: 12px !important;
    max-width: none;
    flex: 0 0 auto;
  }
}

@media (max-width: 400px) {
  .logo a { font-size: 14px !important; max-width: 26vw; }
  .nav-links a { font-size: 12px !important; padding: 4px 4px !important; }
  .nav-links .register-btn { padding: 4px 7px !important; }
  .navbar-inner { padding: 6px 8px !important; gap: 6px; }
  .nav-left { gap: 6px !important; }
}

/* ==========================================================
   首页 Hero 卡片：收窄、缩小，标题单行不折
   ========================================================== */
.hero {
  max-width: 560px !important;
  margin: 10px auto 34px !important;
  padding: 26px 24px 24px !important;
  background: rgba(255, 255, 255, .86) !important;
  backdrop-filter: blur(12px);
  border: 1px solid rgba(47, 111, 237, .16) !important;
  border-radius: 20px !important;
  box-shadow: 6px 6px 0 #d9e8ff !important;
}

.hero .avatar {
  width: 82px !important;
  height: 82px !important;
  margin: 0 auto 14px !important;
  font-size: 32px !important;
}

.hero .avatar img {
  width: 82px !important;
  height: 82px !important;
  border-radius: 50%;
  object-fit: cover;
}

.hero h1 {
  font-size: clamp(19px, 4.4vw, 26px) !important;
  line-height: 1.3 !important;
  letter-spacing: -.2px;
  margin-bottom: 8px !important;
  white-space: nowrap !important;
}

.hero p {
  font-size: 13.5px !important;
  line-height: 1.6 !important;
}

@media (max-width: 640px) {
  .hero {
    max-width: 100% !important;
    margin: 4px auto 26px !important;
    padding: 20px 16px 18px !important;
    box-shadow: 5px 5px 0 #d9e8ff !important;
  }
  .hero .avatar,
  .hero .avatar img {
    width: 66px !important;
    height: 66px !important;
  }
  .hero .avatar { margin-bottom: 10px !important; }
  .hero h1 {
    font-size: clamp(17px, 5.2vw, 22px) !important;
    margin-bottom: 6px !important;
  }
  .hero p { font-size: 12.5px !important; }
}

/* Hero 标题兜底：万一以后标题变长也不会溢出卡片 */
.hero h1 {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ==========================================================
   Hero 卡片：再压扁一档、字号再减小（覆盖前面的取值）
   ========================================================== */
body.is-home .hero,
.hero {
  max-width: 520px !important;
  margin: 6px auto 26px !important;
  padding: 18px 20px 16px !important;
  border-radius: 18px !important;
  box-shadow: 5px 5px 0 #d9e8ff !important;
}

.hero .avatar,
.hero .avatar img {
  width: 62px !important;
  height: 62px !important;
}
.hero .avatar { margin: 0 auto 10px !important; font-size: 26px !important; }

.hero h1 {
  font-size: clamp(15px, 3.4vw, 20px) !important;
  line-height: 1.25 !important;
  margin: 0 0 6px !important;
  white-space: nowrap !important;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hero p {
  font-size: 12px !important;
  line-height: 1.5 !important;
  margin: 0 !important;
}

@media (max-width: 640px) {
  body.is-home .hero,
  .hero {
    max-width: 100% !important;
    margin: 2px auto 20px !important;
    padding: 16px 14px 14px !important;
    box-shadow: 4px 4px 0 #d9e8ff !important;
  }
  .hero .avatar,
  .hero .avatar img {
    width: 52px !important;
    height: 52px !important;
  }
  .hero .avatar { margin-bottom: 8px !important; }
  .hero h1 {
    font-size: clamp(14px, 4.2vw, 18px) !important;
    margin-bottom: 4px !important;
  }
  .hero p { font-size: 11.5px !important; }
}

/* ==========================================================
   首页 Hero 上移到「海平面」位置（贴合地平线）
   海面占海面头图下方 44%，地平线约在 56% 处：
     桌面 360px × 56% ≈ 202px  → 卡片顶部需上移 158px
     手机 230px × 56% ≈ 129px  → 上移 101px
   ========================================================== */
body.is-home .container {
  padding-top: 0 !important;
}

body.is-home .hero {
  position: relative;
  z-index: 2;
  margin-top: -158px !important;
}

@media (max-width: 640px) {
  body.is-home .hero {
    margin-top: -101px !important;
  }
}

/* ==========================================================
   Hero 位置：改用「头图高度百分比」计算，随屏宽自动贴合海平面
   再往上一点：系数 0.53（原来桌面是固定 -158px）
   ========================================================== */
body.is-home {
  --band-h: 360px;
}

body.is-home .sea-band {
  height: var(--band-h) !important;
}

body.is-home .container {
  padding-top: 0 !important;
}

body.is-home .hero {
  position: relative;
  z-index: 2;
  margin-top: calc(var(--band-h) * -0.53) !important;
}

/* 手机/平板统一走这一档（断点放宽到 768px，覆盖更多机型） */
@media (max-width: 768px) {
  body.is-home {
    --band-h: 230px;
  }
  body.is-home .hero {
    margin-top: calc(var(--band-h) * -0.53) !important;
  }
}

/* ==========================================================
   Hero 垂直居中对齐海平面
   海面占头图下方 44%，地平线在 56% 处 ⇒ 视觉上移 0.44 × 头图高度
   再配合 translateY(-50%)，让卡片「中心」落在海平面上，
   与卡片自身高度无关（改字号/头像也不会跑位）
   ========================================================== */
body.is-home .hero {
  position: absolute !important;
  left: 50% !important;
  top: calc(var(--band-h) * -0.44) !important;
  transform: translate(-50%, -50%) !important;
  width: min(520px, calc(100% - 32px)) !important;
  max-width: none !important;
  margin: 0 !important;
  z-index: 2;
}

/* 卡片已脱离文档流，标题自然贴到头图下沿 */
body.is-home .section-title {
  margin-top: 0 !important;
}

/* ==========================================================
   文章卡片标签 + 悬浮染色 改粉色系
   ========================================================== */
.post-meta .tag {
  background: rgba(255, 123, 171, .18) !important;
  color: #d6467e !important;
  border: 1px solid rgba(255, 123, 171, .40) !important;
  border-radius: 999px !important;
  padding: 2px 10px !important;
  font-weight: 600;
}

/* 文章页标题下的标签也统一成粉色，保持一致 */
.article-meta .tag {
  background: rgba(255, 123, 171, .16) !important;
  color: #d6467e !important;
  border: 1px solid rgba(255, 123, 171, .38) !important;
  border-radius: 999px !important;
}

/* 鼠标跟随光斑：绿 → 粉 */
.post::before {
  background: radial-gradient(
    circle at var(--x, 50%) var(--y, 50%),
    rgba(255, 123, 171, .32) 0%,
    rgba(255, 123, 171, .12) 35%,
    rgba(255, 123, 171, 0) 62%
  ) !important;
}

/* 悬浮时卡片描边转粉色 */
.post:hover {
  border-color: rgba(255, 123, 171, .48) !important;
}

/* 悬浮时覆盖文字的那层渐变也带一点粉底 */
.post:hover::after {
  background: linear-gradient(
    to top,
    rgba(82, 30, 56, .88) 0%,
    rgba(82, 30, 56, .58) 45%,
    rgba(82, 30, 56, .16) 100%
  ) !important;
}

/* 悬浮时标题提亮为浅粉 */
.post:hover .post-content h2 {
  color: #ffe4ef !important;
}

/* ---------- 标签配色再调淡（覆盖上面的粉色取值） ---------- */
.post-meta .tag {
  background: rgba(255, 150, 190, .11) !important;
  color: #e07d9e !important;
  border: 1px solid rgba(255, 150, 190, .26) !important;
}

.article-meta .tag {
  background: rgba(255, 150, 190, .10) !important;
  color: #e07d9e !important;
  border: 1px solid rgba(255, 150, 190, .24) !important;
}

/* ==========================================================
   文章卡片新布局：左侧 1:1 圆角封面 | 淡粉分割线 | 右侧文字
   同时去掉封面暗化蒙版
   ========================================================== */
.post {
  display: flex !important;
  align-items: stretch !important;
  height: auto !important;
  aspect-ratio: auto !important;
  padding: 12px !important;
  background: #ffffff !important;
  border: 1px solid rgba(47, 111, 237, .18) !important;
  border-radius: 18px !important;
  box-shadow: 8px 8px 0 #d3e5ff !important;
  overflow: hidden !important;
  margin: 0 !important;
}

/* 去掉暗化蒙版与整卡光斑 */
.post::after { display: none !important; }
.post::before { display: none !important; }

/* 左侧封面：1:1 圆角正方形 */
.post-thumb {
  flex: 0 0 auto;
  width: 152px;
  aspect-ratio: 1 / 1;
  border-radius: 14px;
  overflow: hidden;
  background: #eef2fb;
  position: relative;
}

.post-thumb img,
.post .post-cover {
  position: static !important;
  inset: auto !important;
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  transform: none !important;
  filter: none !important;
  display: block !important;
  border-radius: 14px;
}

/* 悬浮时只在封面图上叠一层淡粉，不再压暗 */
.post:hover .post-thumb::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 14px;
  background: rgba(255, 123, 171, .16);
}

/* 右侧内容区：淡粉实心分割线 */
.post-content {
  flex: 1 1 auto;
  min-width: 0;
  height: auto !important;
  margin-left: 14px !important;
  padding: 2px 2px 2px 16px !important;
  border-left: 2px solid #ffd8e6 !important;
  display: flex !important;
  flex-direction: column !important;
  justify-content: flex-start !important;
  align-items: flex-start !important;
  text-align: left !important;
  gap: 6px;
}

.post-content h2,
.post-content h2.post-title {
  font-size: 17px !important;
  line-height: 1.42 !important;
  font-weight: 700;
  color: var(--ink) !important;
  margin: 0 !important;
  text-shadow: none !important;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.post:hover .post-content h2 { color: #d6467e !important; }

.post-summary {
  font-size: 12.5px !important;
  line-height: 1.65 !important;
  color: var(--muted) !important;
  text-shadow: none !important;
  margin: 0 !important;
  -webkit-line-clamp: 2;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* 底部：标签 + 日期 */
.post-meta {
  margin: auto 0 0 0 !important;
  padding: 0 !important;
  display: flex !important;
  flex-wrap: wrap !important;
  align-items: center !important;
  gap: 6px !important;
  width: 100%;
  font-size: 12px !important;
  color: var(--muted) !important;
  text-shadow: none !important;
}
.post-meta .tag { margin-left: 0 !important; }
.post-date {
  margin-left: auto;
  font-size: 11.5px;
  color: var(--muted);
  white-space: nowrap;
}

@media (max-width: 640px) {
  .post { padding: 10px !important; box-shadow: 5px 5px 0 #d3e5ff !important; }
  .post-thumb { width: 104px; border-radius: 12px; }
  .post-thumb img, .post .post-cover { border-radius: 12px; }
  .post-content { margin-left: 10px !important; padding-left: 12px !important; gap: 4px; }
  .post-content h2, .post-content h2.post-title { font-size: 15px !important; }
  .post-summary { font-size: 11.5px !important; -webkit-line-clamp: 1; }
  .post-date { font-size: 11px; }
}

/* ==========================================================
   文章页顶部横幅：用文章封面图，下半部分渐变过渡到页面底色
   ========================================================== */
.cover-band {
  position: relative;
  z-index: 0;
  height: 340px;
  background-size: cover;
  background-position: center 32%;
  background-repeat: no-repeat;
  background-color: #e8eef8;
  pointer-events: none;
}

/* 下半部分渐变遮罩：让横幅自然过渡到正文 */
.cover-band::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(
      180deg,
      rgba(244, 247, 252, 0) 34%,
      rgba(244, 247, 252, .35) 58%,
      rgba(244, 247, 252, .78) 80%,
      var(--bg) 100%
    );
}

/* 顶部再压一点点，避免亮图顶到导航栏显得刺眼 */
.cover-band::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(23, 41, 63, .10) 0%, rgba(23, 41, 63, 0) 22%);
}

@media (max-width: 640px) {
  .cover-band { height: 200px; background-position: center 28%; }
}

/* ==========================================================
   手机端表格：不再顶出右边界，改为表内横向滚动
   ========================================================== */
@media (max-width: 640px) {
  .article-content table {
    display: block;
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: 10px;
    font-size: 12.5px !important;
  }
  .article-content thead,
  .article-content tbody {
    display: table;
    width: 100%;
    border-collapse: collapse;
  }
  .article-content thead th,
  .article-content tbody td {
    padding: 8px 10px !important;
    font-size: 12.5px !important;
  }
  .article-content td:first-child {
    min-width: 150px !important;
    white-space: normal !important;
  }
}

/* ==========================================================
   表格：外层滚动容器 + 单一表格布局（表头与内容共用列宽）
   覆盖之前拆 thead/tbody 的错误写法
   ========================================================== */
.article-content .table-wrap {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 20px 0 24px;
}

.article-content .table-wrap > table {
  display: table !important;
  width: 100% !important;
  min-width: 0;
  margin: 0 !important;
  border-collapse: collapse !important;
}

/* 表格结构恢复为真正的表格分组，不再各自成表 */
.article-content thead {
  display: table-header-group !important;
  width: auto !important;
}
.article-content tbody {
  display: table-row-group !important;
  width: auto !important;
}
.article-content tr { display: table-row !important; }
.article-content th,
.article-content td { display: table-cell !important; }

@media (max-width: 640px) {
  .article-content .table-wrap > table {
    min-width: 520px;        /* 不够宽就在容器里左右滑，列宽始终一致 */
  }
  .article-content thead th,
  .article-content tbody td {
    padding: 8px 10px !important;
    font-size: 12.5px !important;
  }
  .article-content td:first-child {
    min-width: 150px !important;
    white-space: normal !important;
  }
}

/* ==========================================================
   Hero 下方社交圆点
   ========================================================== */
.social-row {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 14px;
  margin-top: 18px;
  flex-wrap: wrap;
}

.social-dot {
  width: 38px;
  height: 38px;
  flex: 0 0 auto;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #ffffff;
  color: #7d8fa6;
  border: 1px solid rgba(47, 111, 237, .16);
  box-shadow: 3px 3px 0 #e4eeff;
  text-decoration: none;
  transition: transform .22s ease, box-shadow .22s ease, color .22s ease, background .22s ease, border-color .22s ease;
}

.social-dot svg {
  width: 19px;
  height: 19px;
  fill: currentColor;
  display: block;
}

.social-dot span {
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: .4px;
  line-height: 1;
  font-family: 'Segoe UI', Arial, sans-serif;
}

.social-dot:hover {
  transform: translateY(-3px);
  box-shadow: 6px 6px 0 #d3e5ff;
  text-decoration: none;
}

/* 各自品牌色（仅 hover 时显现，平时保持统一灰蓝） */
.social-dot.steam:hover  { color: #1b6f9c; background: #eaf6ff; border-color: rgba(27, 111, 156, .28); }
.social-dot.bili:hover   { color: #00a1d6; background: #e8f9ff; border-color: rgba(0, 161, 214, .30); }
.social-dot.github:hover { color: #24292f; background: #f3f5f8; border-color: rgba(36, 41, 47, .22); }
.social-dot.bgm:hover    { color: #e8688a; background: #fff0f4; border-color: rgba(240, 145, 153, .45); }
.social-dot.osu:hover    { color: #ff66aa; background: #fff0f7; border-color: rgba(255, 102, 170, .38); }

@media (max-width: 640px) {
  .social-row { gap: 10px; margin-top: 14px; }
  .social-dot { width: 34px; height: 34px; box-shadow: 2px 2px 0 #e4eeff; }
  .social-dot svg { width: 17px; height: 17px; }
  .social-dot span { font-size: 8.5px; letter-spacing: .2px; }
}

/* ==========================================================
   正文媒体元素：不超出文章容器（图片/视频/iframe/代码块）
   ========================================================== */
.article-content img {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 20px auto;
  border-radius: 10px;
  background: var(--surface-2);
  box-shadow: 4px 4px 0 #e4eeff;
}

.article-content iframe,
.article-content video,
.article-content embed,
.article-content object {
  max-width: 100%;
  display: block;
  margin: 20px auto;
  border-radius: 10px;
}

.article-content svg { max-width: 100%; height: auto; }

.article-content pre,
.article-content .table-wrap {
  max-width: 100%;
}

/* 超长链接/单词不撑破行宽 */
.article-content a { overflow-wrap: anywhere; }
.article-content { overflow-wrap: break-word; }

@media (max-width: 640px) {
  .article-content img,
  .article-content iframe,
  .article-content video {
    margin: 16px auto;
    border-radius: 8px;
    box-shadow: 3px 3px 0 #e4eeff;
  }
}

/* ==========================================================
   社交圆点：挂到 Hero 卡片正下方（脱离卡片的高度计算）
   top:100% 定位到卡片下沿，卡片本身尺寸与居中位置都不受影响
   ========================================================== */
body.is-home .hero .social-row {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  margin-top: 12px;
  z-index: 3;
  justify-content: center;
}

@media (max-width: 640px) {
  body.is-home .hero .social-row {
    margin-top: 10px;
  }
}

/* ==========================================================
   「最新文章」标题：与上方社交圆点拉开距离
   ========================================================== */
body.is-home .section-title {
  margin-top: 28px !important;
}

@media (max-width: 640px) {
  body.is-home .section-title {
    margin-top: 40px !important;   /* 手机上圆点更靠下，标题需要让出更多空间 */
  }
}

/* ---------- 按实测值修正：标题必须让开圆点 ---------- */
body.is-home .section-title {
  margin-top: 40px !important;   /* 桌面：圆点底 → 标题 ≈ 43px */
}

@media (max-width: 640px) {
  body.is-home .section-title {
    margin-top: 74px !important; /* 手机：圆点底在容器顶下方 49px，再留 25px 间距 */
  }
}

/* ---------- 正确做法：用容器 padding 让开圆点（避免外边距塌陷） ---------- */
body.is-home .container {
  padding-top: 34px !important;   /* 桌面：圆点底距容器顶 3px + 31px 间距 */
}

body.is-home .section-title {
  margin-top: 0 !important;
}

@media (max-width: 640px) {
  body.is-home .container {
    padding-top: 74px !important; /* 手机：圆点底距容器顶 49px + 25px 间距 */
  }
}

/* ---------- 间距收敛到目标值（实测：gap = padding - 偏移量） ---------- */
body.is-home .container {
  padding-top: 10px !important;   /* 桌面：目标间距 ≈ 41px */
}

@media (max-width: 640px) {
  body.is-home .container {
    padding-top: 34px !important; /* 手机：目标间距 ≈ 25px */
  }
}

/* ==========================================================
   动效层（参考「野地 · Field Notes」的节奏）
   全部由 html.js 门控：脚本没加载时内容照常可见
   ========================================================== */

/* 缓动曲线，跟参考项目保持一致的手感 */
:root {
  --ease-out: cubic-bezier(.22, .61, .36, 1);
  --ease-spring: cubic-bezier(.34, 1.4, .64, 1);
}

/* ---------- 滚动揭示 ---------- */
html.js [data-reveal] {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity .8s var(--ease-out),
    transform .8s var(--ease-out);
  transition-delay: var(--reveal-delay, 0ms);
  will-change: opacity, transform;
}

html.js [data-reveal].is-revealed {
  opacity: 1;
  transform: translateY(0);
}

/* ---------- 封面揭幕（clip-path 从上往下刷出） ---------- */
html.js [data-reveal] .post-thumb {
  clip-path: inset(0 0 100% 0);
  transition: clip-path .95s var(--ease-out);
  transition-delay: calc(var(--reveal-delay, 0ms) + 60ms);
}
html.js [data-reveal].is-revealed .post-thumb {
  clip-path: inset(0 0 0 0);
}

/* ---------- 遮罩式标题入场 ---------- */
.hero h1 .mask {
  display: block;
  overflow: hidden;
  padding-bottom: .08em;
}
.hero h1 .mask > span {
  display: block;
  transform: translateY(112%) skewY(2deg);
}
html.js .hero h1 .mask > span {
  animation: mask-rise 1.05s var(--ease-out) .14s forwards;
}
@keyframes mask-rise {
  from { transform: translateY(112%) skewY(2deg); }
  to   { transform: translateY(0) skewY(0); }
}

/* ---------- 头像与副标题的入场 ---------- */
html.js .hero .avatar {
  animation: soft-in .8s var(--ease-out) both;
}
html.js .hero > p {
  animation: soft-in .8s var(--ease-out) .34s both;
}
@keyframes soft-in {
  from { opacity: 0; transform: translateY(10px) scale(.96); }
  to   { opacity: 1; transform: none; }
}

/* ---------- 社交圆点：逐个弹入（只动透明度，避免盖掉 hover 位移） ---------- */
html.js .social-row .social-dot {
  animation: dot-fade .5s var(--ease-out) both;
}
html.js .social-row .social-dot:nth-child(1) { animation-delay: .40s; }
html.js .social-row .social-dot:nth-child(2) { animation-delay: .48s; }
html.js .social-row .social-dot:nth-child(3) { animation-delay: .56s; }
html.js .social-row .social-dot:nth-child(4) { animation-delay: .64s; }
html.js .social-row .social-dot:nth-child(5) { animation-delay: .72s; }
@keyframes dot-fade {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* ---------- 顶部滚动进度线 ---------- */
.scroll-line {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 3px;
  z-index: 999;
  pointer-events: none;
}
.scroll-line span {
  display: block;
  height: 100%;
  transform: scaleX(0);
  transform-origin: 0 50%;
  background: linear-gradient(90deg, #ff9dc0, #6aa8f0);
  border-radius: 0 3px 3px 0;
  transition: transform .12s linear;
}

/* ---------- 导航栏滚动状态 ---------- */
.navbar.is-scrolled {
  box-shadow: 0 6px 22px rgba(60, 105, 170, .14) !important;
  border-bottom-color: rgba(47, 111, 237, .22) !important;
}

/* ---------- 文章封面横幅：缓慢展开 ---------- */
html.js .cover-band {
  animation: band-in 1.1s var(--ease-out) both;
}
@keyframes band-in {
  from { opacity: .2; transform: scale(1.04); }
  to   { opacity: 1; transform: none; }
}

/* ---------- 卡片 hover 微调：图片比之前更慢一点地推近 ---------- */
.post-card:hover .post-cover-wrap img,
.post:hover .post-thumb img {
  transform: scale(1.06);
}
.post-thumb img {
  transition: transform .9s var(--ease-out);
}

/* ---------- 无障碍：尊重系统「减少动态效果」 ---------- */
@media (prefers-reduced-motion: reduce) {
  html.js [data-reveal],
  html.js [data-reveal].is-revealed {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
  html.js [data-reveal] .post-thumb {
    clip-path: none !important;
    transition: none !important;
  }
  html.js .hero h1 .mask > span,
  html.js .hero .avatar,
  html.js .hero > p,
  html.js .social-row .social-dot,
  html.js .cover-band {
    animation: none !important;
  }
  .scroll-line { display: none; }
}

/* ==========================================================
   作品集：画廊网格 + 图片灯箱
   ========================================================== */

/* 3 列 / 2 列自适应网格，统一 4:5 竖向裁切 */
.gallery {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin: 26px 0 30px;
}

.gallery figure,
.gallery > p {
  margin: 0 !important;
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.gallery img,
.article-content .gallery img {
  width: 100%;
  height: 100%;
  aspect-ratio: var(--gal-ratio, 4 / 5);
  object-fit: cover;
  margin: 0 !important;
  border-radius: 12px !important;
  box-shadow: none !important;
  background: var(--surface-2);
  cursor: zoom-in;
  transition: transform .55s var(--ease-out), filter .3s ease;
}

/* 竖版作品裁切不想要的话，加 class="keep" 即可完整显示 */
.gallery img.keep {
  aspect-ratio: auto;
  object-fit: contain;
}

figure.shot figcaption,
.gallery figcaption {
  font-size: 11.5px;
  line-height: 1.55;
  color: var(--muted);
  padding: 0 2px;
}

@media (max-width: 900px) {
  .gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
}
@media (max-width: 560px) {
  .gallery { gap: 10px; margin: 20px 0 24px; }
  figure.shot figcaption { font-size: 11px; }
}

/* 正文图片可点开放大 */
.article-content img { cursor: zoom-in; }

/* ---------- 灯箱 ---------- */
dialog.lightbox {
  border: none;
  padding: 0;
  margin: 0;
  width: 100vw;
  height: 100vh;
  max-width: 100vw;
  max-height: 100vh;
  background: transparent;
  color: #fff;
}

dialog.lightbox::backdrop {
  background: rgba(12, 22, 38, .88);
  backdrop-filter: blur(6px);
}

.lightbox-inner {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 5vmin;
  box-sizing: border-box;
}

dialog.lightbox img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  border-radius: 10px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, .55);
  background: #10182a;
  cursor: default;
}

.lightbox-close,
.lightbox-nav {
  position: absolute;
  border: none;
  background: rgba(255, 255, 255, .16);
  color: #fff;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  font-size: 19px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(6px);
  transition: background .2s ease;
}
.lightbox-close:hover,
.lightbox-nav:hover { background: rgba(255, 255, 255, .32); }

.lightbox-close { top: 2vmin; right: 2vmin; }
.lightbox-nav.prev { left: 1.6vmin; top: 50%; transform: translateY(-50%); }
.lightbox-nav.next { right: 1.6vmin; top: 50%; transform: translateY(-50%); }
dialog.lightbox.single .lightbox-nav { display: none; }

.lightbox-caption {
  position: absolute;
  left: 0; right: 0; bottom: 2.4vmin;
  text-align: center;
  font-size: 13px;
  opacity: .82;
  padding: 0 8vmin;
}

@media (prefers-reduced-motion: reduce) {
  .gallery img { transition: none !important; }
}

/* ==========================================================
   瀑布流变体：比例差异大时用这个（完整展示，不裁切）
   用法：<div class="gallery gallery--masonry"> ... </div>
   ========================================================== */
.gallery--masonry {
  display: block !important;
  column-count: 3;
  column-gap: 14px;
}

.gallery--masonry figure,
.gallery--masonry > p {
  break-inside: avoid;
  -webkit-column-break-inside: avoid;
  margin: 0 0 14px 0 !important;
}

.gallery--masonry img,
.article-content .gallery--masonry img {
  width: 100%;
  height: auto !important;
  aspect-ratio: auto !important;
  object-fit: contain !important;
  border-radius: 12px !important;
  box-shadow: none !important;
}

@media (max-width: 900px) {
  .gallery--masonry { column-count: 2; column-gap: 12px; }
}
@media (max-width: 560px) {
  .gallery--masonry { column-count: 1; }
  .gallery--masonry figure { margin-bottom: 12px !important; }
}

/* ---------- 修正：横幅入场不再横向放大（原 scale 会让手机端短暂横向溢出） ---------- */
html.js .cover-band {
  animation: band-in-soft 1.1s var(--ease-out) both;
}

@keyframes band-in-soft {
  from { opacity: .35; transform: translateY(10px); }
  to   { opacity: 1; transform: none; }
}

/* 全局兜底：任何 transform 造成的横向溢出都不产生横向滚动条 */
html {
  overflow-x: clip;
}

/* ==========================================================
   站名标识：自托管 Outfit（几何无衬线，适合小写域名）
   仅用于左上角 logo，不加载中文，因此文件只有 32 KB
   ========================================================== */
@font-face {
  font-family: "Outfit";
  src: url("/static/fonts/outfit-latin-var.woff2") format("woff2-variations"),
       url("/static/fonts/outfit-latin-var.woff2") format("woff2");
  font-weight: 300 800;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
                 U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193,
                 U+2212, U+2215, U+FEFF, U+FFFD;
}

.logo a {
  font-family: "Outfit", "Segoe UI Variable Display", "Segoe UI",
               system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif !important;
  font-size: 19px !important;
  font-weight: 600 !important;
  letter-spacing: -.2px;
  font-feature-settings: "ss01" 1;
  /* 让 ppysb 与 .icu 之间有一点呼吸感 */
  word-spacing: .5px;
}

.logo a:hover {
  letter-spacing: 0;
  transition: letter-spacing .3s var(--ease-out), color .3s ease;
}

@media (max-width: 680px) {
  .logo a { font-size: 16.5px !important; letter-spacing: -.1px; }
}
@media (max-width: 400px) {
  .logo a { font-size: 15px !important; }
}

/* ==========================================================
   首页卡片：静止态在「实心阴影板」的终止位置加一圈细边框
   做法：两条同偏移的 box-shadow —— 第二条用 1.5px spread 描边，
   正好贴着淡蓝板的外缘，不需要伪元素（卡片本身 overflow:hidden）
   ========================================================== */
.post {
  box-shadow:
    8px 8px 0 #d3e5ff,
    8px 8px 0 1.5px rgba(47, 111, 237, .26) !important;
}

.post:hover {
  box-shadow:
    11px 11px 0 #c2dbff,
    11px 11px 0 1.5px rgba(47, 111, 237, .32) !important;
}

@media (max-width: 640px) {
  .post {
    box-shadow:
      5px 5px 0 #d3e5ff,
      5px 5px 0 1px rgba(47, 111, 237, .26) !important;
  }
  .post:hover {
    box-shadow:
      7px 7px 0 #c2dbff,
      7px 7px 0 1px rgba(47, 111, 237, .32) !important;
  }
}

/* ---------- 撤销上一轮误解添加的阴影细框 ---------- */
.post {
  box-shadow: 8px 8px 0 #d3e5ff !important;
}
.post:hover {
  box-shadow: 11px 11px 0 #c2dbff !important;
}
@media (max-width: 640px) {
  .post { box-shadow: 5px 5px 0 #d3e5ff !important; }
  .post:hover { box-shadow: 7px 7px 0 #c2dbff !important; }
}

/* ==========================================================
   未揭示态：卡片显示「骨架占位」，而不是整块透明
   —— 让首屏下方一眼能看到还有内容，不会显得文章很少
   ========================================================== */
html.js .post[data-reveal]:not(.is-revealed) {
  opacity: 1 !important;
  transform: translateY(14px) !important;
  background: repeating-linear-gradient(
    135deg,
    rgba(47, 111, 237, .055) 0px,
    rgba(47, 111, 237, .055) 8px,
    rgba(47, 111, 237, .015) 8px,
    rgba(47, 111, 237, .015) 16px
  ) !important;
  border: 1px dashed rgba(47, 111, 237, .30) !important;
  box-shadow: none !important;
  transition:
    transform .6s var(--ease-out),
    border-color .4s ease,
    background .4s ease;
}

/* 骨架里不放真实内容，只留一个居中提示 */
html.js .post[data-reveal]:not(.is-revealed) > * {
  opacity: 0 !important;
  transition: opacity .45s ease;
}

html.js .post[data-reveal]:not(.is-revealed)::after {
  content: "· · ·";
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  letter-spacing: 6px;
  color: rgba(47, 111, 237, .32);
  z-index: 4;
  pointer-events: none;
}

/* 揭示完成后：内容淡入，骨架样式自然撤掉 */
html.js .post[data-reveal].is-revealed {
  opacity: 1 !important;
  background: #ffffff !important;
  border: 1px solid rgba(47, 111, 237, .18) !important;
}

@media (prefers-reduced-motion: reduce) {
  html.js .post[data-reveal]:not(.is-revealed) {
    background: #ffffff !important;
    border: 1px solid rgba(47, 111, 237, .18) !important;
    transform: none !important;
  }
  html.js .post[data-reveal]:not(.is-revealed)::after { content: none; }
}

/* 骨架态需要重新启用 ::after（此前被 .post::after{display:none} 关掉了） */
html.js .post[data-reveal]:not(.is-revealed)::after {
  display: flex !important;
  content: "· · ·" !important;
  align-items: center !important;
  justify-content: center !important;
  background: none !important;
  inset: 0 !important;
  font-size: 28px;
  letter-spacing: 8px;
  color: rgba(47, 111, 237, .30);
  z-index: 4;
  pointer-events: none;
}

html.js .post[data-reveal].is-revealed::after {
  display: none !important;
}

/* 提示点加深一档，避免看不清 */
html.js .post[data-reveal]:not(.is-revealed)::after {
  color: rgba(47, 111, 237, .45) !important;
  font-size: 30px !important;
  letter-spacing: 9px !important;
}

/* ==========================================================
   未揭示态改为「蒙版」方案：
   - 卡片本体保持完整（不再把内容透明化）
   - 上滑强度恢复原始 24px
   - 蒙版 = 白底 + 斜纹 + 虚线框 + 中心「· · ·」，揭示时淡出
   ========================================================== */

/* 1) 卡片本体：恢复原始位移动画，内容不透明 */
html.js .post[data-reveal]:not(.is-revealed) {
  opacity: 1 !important;
  transform: translateY(24px) !important;
  background: #ffffff !important;
  border: 1px solid rgba(47, 111, 237, .18) !important;
  box-shadow: 8px 8px 0 #d3e5ff !important;
  transition: transform .8s var(--ease-out), box-shadow .3s ease, border-color .3s ease;
}

html.js .post[data-reveal]:not(.is-revealed) > * {
  opacity: 1 !important;
}

/* 2) 蒙版层：覆盖整张卡片 */
html.js .post[data-reveal]::after {
  content: "· · ·";
  position: absolute;
  inset: 0;
  z-index: 5;
  display: flex !important;
  align-items: center;
  justify-content: center;
  border-radius: 18px;
  border: 1px dashed rgba(47, 111, 237, .32);
  background:
    repeating-linear-gradient(
      135deg,
      rgba(47, 111, 237, .06) 0px,
      rgba(47, 111, 237, .06) 8px,
      rgba(47, 111, 237, .015) 8px,
      rgba(47, 111, 237, .015) 16px
    ),
    rgba(255, 255, 255, .95);
  color: rgba(47, 111, 237, .45);
  font-size: 30px;
  letter-spacing: 9px;
  pointer-events: none;
  opacity: 1;
  transition: opacity .5s ease .1s;
}

/* 3) 揭示后蒙版淡出 */
html.js .post[data-reveal].is-revealed::after {
  opacity: 0;
  transition: opacity .45s ease;
}

/* 非 data-reveal 的卡片保持没有蒙版 */
html.js .post:not([data-reveal])::after {
  display: none !important;
}

@media (max-width: 640px) {
  html.js .post[data-reveal]:not(.is-revealed) {
    box-shadow: 5px 5px 0 #d3e5ff !important;
  }
  html.js .post[data-reveal]::after {
    border-radius: 16px;
    font-size: 26px;
    letter-spacing: 7px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html.js .post[data-reveal]:not(.is-revealed) { transform: none !important; }
  html.js .post[data-reveal]::after { display: none !important; }
}

/* 蒙版改为不透明白底，避免下方文字透出来显脏 */
html.js .post[data-reveal]::after {
  background:
    repeating-linear-gradient(
      135deg,
      rgba(47, 111, 237, .07) 0px,
      rgba(47, 111, 237, .07) 8px,
      rgba(47, 111, 237, .02) 8px,
      rgba(47, 111, 237, .02) 16px
    ),
    #ffffff;
  color: rgba(47, 111, 237, .50);
  font-size: 34px;
  letter-spacing: 10px;
}

@media (max-width: 640px) {
  html.js .post[data-reveal]::after {
    font-size: 28px;
    letter-spacing: 8px;
  }
}

/* 覆盖早前骨架规则里的 background:none !important，让蒙版真正不透明 */
html.js .post[data-reveal]:not(.is-revealed)::after {
  display: flex !important;
  content: "· · ·" !important;
  position: absolute !important;
  inset: 0 !important;
  z-index: 6 !important;
  align-items: center !important;
  justify-content: center !important;
  border-radius: 18px !important;
  border: 1px dashed rgba(47, 111, 237, .32) !important;
  background:
    repeating-linear-gradient(
      135deg,
      rgba(47, 111, 237, .07) 0px,
      rgba(47, 111, 237, .07) 8px,
      rgba(47, 111, 237, .02) 8px,
      rgba(47, 111, 237, .02) 16px
    ),
    #ffffff !important;
  color: rgba(47, 111, 237, .50) !important;
  font-size: 34px !important;
  letter-spacing: 10px !important;
  pointer-events: none !important;
  opacity: 1;
  transition: opacity .5s ease .1s;
}

html.js .post[data-reveal].is-revealed::after {
  opacity: 0 !important;
  display: flex !important;
  transition: opacity .45s ease !important;
}

@media (max-width: 640px) {
  html.js .post[data-reveal]:not(.is-revealed)::after {
    border-radius: 16px !important;
    font-size: 28px !important;
    letter-spacing: 8px !important;
  }
}
