:root {
  --accent: #2f9bd6;
  --accent-dark: #1d7ab8;
  --accent-light: #eaf5fc;
  --text: #2c3e50;
  --muted: #4a5a6a;
  --bg: #ffffff;
}

* { box-sizing: border-box; }

html {
  min-height: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Times New Roman", "汉仪颜楷简", "STKaiti", "KaiTi", "楷体", serif;
  color: var(--text);
  background: url("img-bg-mv.png") center top / cover no-repeat fixed;
  background-color: #2e4a7a;
  line-height: 1.7;
}

.container {
  position: relative;
  z-index: 1;
  max-width: 640px;
  margin: 0 auto;
  padding: 48px 24px;
}

/* 分享页：随笔/资源是长文，电脑上放宽行宽；涂鸦/合影保持窄版式。
   只在 share.html（body.share-page）且单独看随笔/资源（.share-wide）时生效。 */
body.share-page.share-wide .container {
  max-width: 960px;
}

/* 分享栏列表页：加宽到屏幕约 2/3（70vw），减少两侧留白；设 1400px 上限防止超宽屏过宽 */
body.share-list .container {
  max-width: min(70vw, 1400px);
}

/* 管理后台：与分享栏一致，加宽到屏幕约 2/3 */
body.admin-page .container {
  max-width: min(70vw, 1400px);
}

.avatar {
  display: block;
  width: 96px;
  height: 96px;
  object-fit: cover;
  border-radius: 50%;
  border: 3px solid var(--accent-light);
  margin-bottom: 16px;
}

.hero h1 {
  margin: 0 0 8px;
  font-size: 32px;
  font-weight: 600;
}

.subtitle {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 16px;
}

.motto {
  margin: 0;
  color: var(--accent-dark);
  font-size: 15px;
}

section h2 {
  position: relative;
  font-size: 18px;
  font-weight: 600;
  margin: 32px 0 12px;
  padding-left: 28px;
}
/* 圣巢标志装饰：标题左侧图标 */
section h2::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 1.31em;
  height: 2em;
  background: url("img-monument.png?v=2") no-repeat center / contain;
}

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

.contact li {
  margin: 8px 0;
  word-break: break-all;
}

a {
  color: var(--accent-dark);
  text-decoration: none;
}

a:hover { text-decoration: underline; }

.back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  color: #d9ecfb;
  text-shadow: 0 1px 6px rgba(8, 24, 48, .5);
}
.back:hover { color: #fff; }
.back-arrow {
  height: 44px;
  width: auto;
  filter: drop-shadow(0 1px 3px rgba(8, 24, 48, .5));
}

.work h1 {
  font-size: 26px;
  font-weight: 600;
  margin: 8px 0 16px;
  color: #fff;
  text-shadow: 0 1px 8px rgba(8, 24, 48, .55);
}

.work-img {
  display: block;
  width: 100%;
  max-height: 70vh;
  object-fit: contain;
  border-radius: 12px;
  margin-bottom: 8px;
  background: #fff;
}

.work section {
  background: rgba(255, 255, 255, .93);
  border: 1px solid rgba(255, 255, 255, .6);
  border-radius: 12px;
  padding: 4px 16px 16px;
  margin-top: 16px;
}
.work section h2 { margin-top: 16px; }
.work section p {
  margin: 8px 0 0;
}
/* 正文段落（随笔/资源长文）：拆段后的 <p>，行高更舒展 */
.work section p.work-para {
  margin: 0 0 14px;
  font-size: 15px;
  line-height: 1.9;
  text-align: justify;
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: break-word;
}
.work section p.work-para:last-child { margin-bottom: 0; }
/* 空行占位：只撑开段落间距，不显示内容 */
.work section p.work-para-empty {
  height: 0;
  margin: 0;
}

/* 作品详情页操作按钮区（资源类：下载文档 / 打开外链） */
.work-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 16px;
}
.work-btn {
  display: inline-block;
  padding: 10px 22px;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  transition: background .15s, box-shadow .15s;
}
.work-btn:hover {
  background: var(--accent-dark);
  box-shadow: 0 0 0 3px rgba(47, 155, 214, .18);
  text-decoration: none;
}

/* 作品详情页「上一个/下一个」左右浮动箭头按钮 */
.work-pager {
  position: fixed;
  top: 50%;
  left: 0;
  right: 0;
  z-index: 10;
  pointer-events: none;
  transform: translateY(-50%);
}
.pager-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 64px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: center;
  /* 按钮内容改为装饰性箭头图（img-arrow-left/right.png），无文字 */
  font-size: 0;
  line-height: 1;
  color: #2c3e50;
  text-decoration: none;
  background: rgba(255, 255, 255, .35);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, .55);
  border-radius: 50%;
  pointer-events: auto;
  transition: background .15s, border-color .15s, transform .15s;
}
.pager-btn:hover {
  background: rgba(255, 255, 255, .5);
  border-color: #fff;
  text-decoration: none;
  transform: translateY(-50%) scale(1.06);
}
.pager-btn img {
  display: block;
  height: 44px;
  width: auto;
  user-select: none;
  -webkit-user-drag: none;
}
#prev-link { left: 12px; }
#next-link { right: 12px; }
.pager-btn.is-disabled {
  background: rgba(255, 255, 255, .18);
  border-color: rgba(255, 255, 255, .3);
  cursor: default;
  pointer-events: none;
}
.pager-btn.is-disabled img { opacity: .3; }

.work-empty {
  text-align: center;
  padding: 48px 0;
}

.work-empty p {
  color: rgba(255, 255, 255, .9);
  text-shadow: 0 1px 6px rgba(8, 24, 48, .5);
  margin: 0 0 12px;
}

.card-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.card {
  display: block;
  padding: 16px;
  border: 1px solid #e4edf2;
  border-radius: 12px;
  background: var(--accent-light);
  color: var(--text);
  text-decoration: none;
  transition: border-color .15s;
}

.card:hover {
  border-color: var(--accent);
  text-decoration: none;
}

.card-img {
  display: block;
  width: 100%;
  height: 180px;
  object-fit: contain;
  border-radius: 8px;
  margin-bottom: 10px;
  background: #fff;
}

.card h3 {
  margin: 0 0 8px;
  font-size: 16px;
  font-weight: 600;
}

.card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

/* === 分享区块（首页） === */
.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 16px 0 12px;
}
.section-head h2 {
  position: relative;
  margin: 0;
  font-size: 18px;
  font-weight: 600;
  padding-left: 28px;
  color: var(--text);
}
/* 圣巢标志装饰：标题左侧图标 */
.section-head h2::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 1.31em;
  height: 2em;
  background: url("img-monument.png?v=2") no-repeat center / contain;
}
/* 更多链接：大黄蜂图标，低透明度呼吸，悬停亮起蓝色光晕 */
.more {
  display: inline-block;
  width: 1.82em;
  height: 2.3em;
  background: url("img-hornet.png") no-repeat center / contain;
  opacity: .45;
  animation: hornet-breathe 3.2s ease-in-out infinite;
}
.more:hover {
  animation: none;
  opacity: 1;
  filter: drop-shadow(0 0 5px rgba(47, 155, 214, .8)) drop-shadow(0 0 12px rgba(47, 155, 214, .45));
}
@keyframes hornet-breathe {
  0%, 100% { opacity: .35; }
  50% { opacity: .6; }
}

/* === 分享列表页（share.html） === */
.share-head h1 {
  font-size: 26px;
  font-weight: 600;
  margin: 8px 0 4px;
  color: #fff;
  text-shadow: 0 1px 8px rgba(8, 24, 48, .55);
}
.share-sub {
  margin: 0 0 16px;
  color: rgba(255, 255, 255, .88);
  font-size: 14px;
  text-shadow: 0 1px 6px rgba(8, 24, 48, .5);
}
.share-update {
  margin: -10px 0 16px;
  color: rgba(255, 255, 255, .62);
  font-size: 12px;
  text-shadow: 0 1px 5px rgba(8, 24, 48, .4);
}

.filter {
  display: flex;
  gap: 8px;
  margin: 0 0 16px;
}
.filter-btn {
  padding: 6px 16px;
  border: 1px solid #d7e4ec;
  border-radius: 999px;
  background: #fff;
  color: var(--muted);
  font-size: 14px;
  cursor: pointer;
}
.filter-btn.is-active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  align-items: start;
}
/* 修复：display: grid 会压过 hidden 属性的默认隐藏，这里强制 hidden 生效 */
.list[hidden] { display: none; }
.list-item {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 16px;
  border: 1px solid #e4edf2;
  border-radius: 12px;
  background: #fff;
  text-decoration: none;
  color: var(--text);
}
.list-item:hover { border-color: var(--accent); }
/* 单图封面：完整显示（contain），限高防止超大图撑爆卡片 */
.list-thumb {
  width: 100%;
  max-height: 240px;
  object-fit: contain;
  border-radius: 8px;
  background: #fff;
}
/* 分享栏列表里的九宫格缩略图（多图用，朋友圈式小图） */
.list-grid {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 3px;
}
.list-grid[data-count="1"] { grid-template-columns: 1fr; }
.list-grid[data-count="2"],
.list-grid[data-count="4"] { grid-template-columns: repeat(2, 1fr); }
.list-grid-img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 4px;
  background: #fff;
}
/* 单张图：完整显示（contain），限高，不裁切 */
.list-grid[data-count="1"] .list-grid-img {
  aspect-ratio: auto;
  max-height: 240px;
  object-fit: contain;
  background: transparent;
}
.list-body { min-width: 0; }
/* 手机端：窄屏时分享栏自动变单列 */
@media (max-width: 600px) {
  .list { grid-template-columns: 1fr; }
}
.list-title {
  margin: 0 0 4px;
  font-size: 16px;
  font-weight: 600;
  overflow-wrap: anywhere;
  word-break: break-word;
}
.list-desc {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
  line-height: 1.6;
  /* 长简介截断：列表只显示前 3 行，完整内容点进详情阅读 */
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  /* 超长无空格字符强制换行，防止撑破卡片 */
  overflow-wrap: anywhere;
  word-break: break-word;
}
.tag {
  display: inline-block;
  margin-top: 8px;
  padding: 2px 10px;
  border-radius: 999px;
  background: var(--accent-light);
  color: var(--accent-dark);
  font-size: 12px;
}
/* 「下载文档」标签：做成可点击的按钮样式（Day 22 文档上传） */
.tag-file {
  margin-left: 8px;
  background: var(--accent);
  color: #fff;
  cursor: pointer;
  font-weight: 600;
  transition: background .15s;
}
.tag-file:hover { background: var(--accent-dark); }

.state {
  padding: 48px 0;
  text-align: center;
  color: rgba(255, 255, 255, .9);
  text-shadow: 0 1px 6px rgba(8, 24, 48, .5);
}

/* === 登录页（毛玻璃卡片） === */
.login-page {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - 56px);
  padding: 32px 16px;
}
.login-card {
  width: 100%;
  max-width: 360px;
  padding: 32px 28px;
  border-radius: 16px;
  background: rgba(255, 255, 255, .72);
  border: 1px solid rgba(255, 255, 255, .8);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 8px 32px rgba(8, 24, 48, .18);
}
.login-card h1 {
  margin: 0 0 4px;
  font-size: 26px;
  font-weight: 600;
  color: var(--accent-dark);
  text-shadow: none;
}
.login-card .login-sub {
  margin: 0 0 24px;
  font-size: 14px;
  color: rgba(29, 122, 184, .75);
  text-shadow: none;
}
.login-card label {
  display: block;
  margin: 0 0 6px;
  font-size: 13px;
  color: var(--accent-dark);
  font-weight: 600;
  text-shadow: none;
}
.login-card input {
  display: block;
  width: 100%;
  padding: 10px 12px;
  margin: 0 0 16px;
  border: 1px solid rgba(47, 155, 214, .45);
  border-radius: 8px;
  font-size: 14px;
  color: var(--accent-dark);
  background: #fff;
  font-family: inherit;
}
.login-card input::placeholder {
  color: rgba(29, 122, 184, .5);
}
.login-card input:focus {
  outline: none;
  border-color: var(--accent);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(47, 155, 214, .18);
}
.login-card .login-btn {
  display: block;
  width: 100%;
  padding: 10px 0;
  margin-top: 4px;
  border: none;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: background .15s;
}
.login-card .login-btn:hover {
  background: var(--accent-dark);
}
.login-card .login-btn:disabled {
  opacity: .6;
  cursor: not-allowed;
}
.login-error {
  margin: 10px 0 0;
  padding: 8px 12px;
  border-radius: 6px;
  background: #fdeaea;
  color: #c0392b;
  font-size: 13px;
  text-shadow: none;
}
.login-hint {
  margin: 16px 0 0;
  text-align: center;
  font-size: 12px;
  color: rgba(29, 122, 184, .8);
  text-shadow: none;
}
.login-hint a {
  color: var(--accent-dark);
  text-decoration: underline;
}

@media (max-width: 480px) {
  .card-grid { grid-template-columns: 1fr; }
  .container { padding: 32px 16px; }
}

/* === 新首页布局：顶部导航 + 白画布 === */
.topnav {
  position: relative;
  z-index: 2;
  background: var(--accent);
}
.topnav-inner {
  max-width: 760px;
  margin: 0 auto;
  padding: 0 24px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.brand {
  color: #fff;
  font-size: 18px;
  font-weight: 600;
  text-decoration: none;
}
.nav-links {
  display: flex;
  gap: 20px;
}
.nav-links a {
  color: rgba(255, 255, 255, .85);
  font-size: 14px;
  text-decoration: none;
}
.nav-links a:hover { color: #fff; text-decoration: none; }
.nav-links a.is-active {
  color: #fff;
  font-weight: 600;
  border-bottom: 2px solid #fff;
  padding-bottom: 2px;
}

.page {
  position: relative;
  z-index: 1;
  padding: 24px 16px 48px;
}
.sheet {
  max-width: 760px;
  margin: 0 auto;
}

.columns {
  display: flex;
  gap: 16px;
  padding: 0 0 16px;
}
.about {
  flex: 0 0 260px;
  background: rgba(255, 255, 255, .92);
  border: 1px solid rgba(255, 255, 255, .65);
  border-radius: 12px;
  padding: 20px;
}
.intro {
  flex: 1;
  min-width: 0;
  background: rgba(255, 255, 255, .92);
  border: 1px solid rgba(255, 255, 255, .65);
  border-radius: 12px;
  padding: 20px 24px;
}
.intro p {
  margin: 0 0 12px;
  font-size: 14px;
  line-height: 1.8;
  color: var(--text);
  overflow-wrap: break-word;
  word-break: break-word;
}
.intro p:last-child { margin-bottom: 0; }

.col-title {
  margin: 0 0 16px;
  font-size: 18px;
  font-weight: 600;
}

.avatar {
  width: 96px;
  height: 96px;
  object-fit: cover;
  border-radius: 50%;
  border: 3px solid var(--accent-light);
  margin-bottom: 16px;
}
.about-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.about-list li {
  margin: 0 0 10px;
  font-size: 14px;
  line-height: 1.6;
  white-space: nowrap;
  color: var(--text);
}
.about-list li a {
  color: var(--accent-dark);
  text-decoration: underline;
}
.about-list .k {
  display: inline;
  color: var(--muted);
  font-size: 14px;
  margin-right: 6px;
}

.share {
  padding: 0 0 8px;
}
.share .section-head h2 {
  margin: 0;
}
.cat-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}
.cat {
  display: block;
  padding: 16px 12px;
  border: 1px solid #e4edf2;
  border-radius: 12px;
  background: rgba(255, 255, 255, .92);
  text-align: center;
  color: var(--text);
  text-decoration: none;
  transition: border-color .4s, transform .4s, box-shadow .4s;
}
.cat:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
  text-decoration: none;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .55),
              0 0 14px rgba(190, 220, 235, .5),
              0 0 30px rgba(210, 232, 244, .35);
}
.cat-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 76px;
  height: 76px;
  margin-bottom: 8px;
}
.cat-icon svg {
  width: 100%;
  height: 100%;
  display: block;
}
.cat h3 {
  margin: 0 0 4px;
  font-size: 15px;
  font-weight: 600;
}
.cat p {
  margin: 0;
  font-size: 12px;
  color: var(--muted);
}

.contact {
  padding: 8px 24px 24px;
}
.contact ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
.contact li {
  margin: 8px 0;
  word-break: break-all;
}

@media (max-width: 600px) {
  .columns { flex-direction: column; }
  .about { flex: none; margin-bottom: 0; }
  .cat-grid { grid-template-columns: repeat(2, 1fr); }
}

/* === 气泡背景（方案①：纯 CSS 动画） === */
.bubbles {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}
.bubbles i {
  position: absolute;
  bottom: -40px;
  border-radius: 50%;
  background: radial-gradient(circle at 32% 28%, rgba(255, 255, 255, .7), rgba(255, 255, 255, .1) 45%, rgba(133, 183, 235, .16) 100%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .28);
  animation: rise linear infinite;
}
@keyframes rise {
  0%   { transform: translateY(0) scale(.8); opacity: 0; }
  12%  { opacity: .7; }
  85%  { opacity: .35; }
  100% { transform: translateY(-105vh) scale(1.05); opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .bubbles i { animation: none; display: none; }
  .cat-icon animateTransform { animation: none; }
  .stars i { animation: none; display: none; }
}

/* === 流星划过（纯 CSS 动画） === */
.stars {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}
.stars i {
  position: absolute;
  width: 90px;
  height: 2px;
  background: linear-gradient(to right, rgba(255, 255, 255, .95), rgba(255, 255, 255, 0));
  border-radius: 999px;
  transform: rotate(-35deg);
  transform-origin: left center;
  opacity: 0;
  animation: shoot linear infinite;
}
.stars i::before {
  content: "";
  position: absolute;
  left: -1px;
  top: 50%;
  width: 5px;
  height: 5px;
  transform: translateY(-50%);
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 6px 1px rgba(255, 255, 255, .9);
}
@keyframes shoot {
  0%   { transform: rotate(-35deg) translateX(0); opacity: 0; }
  4%   { opacity: 1; }
  18%  { opacity: 1; }
  30%  { opacity: 0; transform: rotate(-35deg) translateX(-34vw); }
  100% { opacity: 0; transform: rotate(-35deg) translateX(-34vw); }
}

/* === 稀疏星光粒子（呼吸闪烁） ===
   静止散布的小光点，每个独立缓慢呼吸（亮度强弱交替 + 轻微缩放），节奏错开避免同步闪烁 */
.starfield {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}
.starfield i {
  position: absolute;
  border-radius: 50%;
  background: radial-gradient(circle,
    rgba(255, 255, 255, 1) 0%,
    rgba(200, 224, 255, .85) 45%,
    rgba(200, 224, 255, 0) 72%);
  box-shadow:
    0 0 6px 2px rgba(255, 255, 255, .75),
    0 0 16px 5px rgba(170, 205, 255, .4);
  opacity: 0;
  animation: twinkle ease-in-out infinite;
}
@keyframes twinkle {
  0%, 100% { opacity: 0; transform: scale(.55); }
  50%      { opacity: 1; transform: scale(1); }
}
@media (prefers-reduced-motion: reduce) {
  .starfield i { animation: none; display: none; }
}

/* === 首页侧栏式布局（个人主页改版，锚点导航 + 区块堆叠，可扩展） === */
.home {
  position: relative;
  z-index: 1;
  max-width: 1080px;
  margin: 0 auto;
  padding: 40px 24px 64px;
  display: flex;
  gap: 32px;
  align-items: flex-start;
}

/* 左侧栏 */
.sidebar {
  flex: 0 0 260px;
  position: sticky;
  top: 40px;
  background: rgba(255, 255, 255, .92);
  border: 1px solid rgba(255, 255, 255, .65);
  border-radius: 16px;
  padding: 28px 24px;
  text-align: center;
  box-shadow: 0 8px 28px rgba(8, 24, 48, .14);
}
.side-avatar {
  display: block;
  width: 110px;
  height: 110px;
  object-fit: cover;
  border-radius: 50%;
  border: 3px solid var(--accent-light);
  margin: 0 auto 14px;
}
.side-name {
  margin: 0 0 4px;
  font-size: 22px;
  font-weight: 600;
  color: var(--text);
}
.side-role {
  margin: 0 0 6px;
  font-size: 13px;
  color: var(--muted);
}
.side-motto {
  margin: 0 0 18px;
  font-size: 13px;
  color: var(--accent-dark);
}
.side-social {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-bottom: 20px;
}
.side-social a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--accent-light);
  border: 1px solid #d5e9f6;
  transition: transform .15s, background .15s;
}
.side-social a:hover {
  background: #d8ecf9;
  transform: translateY(-2px);
}
.side-nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 20px;
}
.side-nav a {
  display: block;
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 15px;
  color: var(--text);
  text-decoration: none;
  transition: background .15s, color .15s;
}
.side-nav a:hover {
  background: var(--accent-light);
  color: var(--accent-dark);
  text-decoration: none;
}
.side-login {
  display: block;
  padding: 9px 0;
  border: 1px solid var(--accent);
  border-radius: 8px;
  color: var(--accent-dark);
  font-size: 14px;
  text-decoration: none;
  transition: background .15s, color .15s;
}
.side-login:hover {
  background: var(--accent);
  color: #fff;
  text-decoration: none;
}

/* 右侧内容区 */
.content {
  flex: 1;
  min-width: 0;
}
.hero {
  padding: 16px 8px 28px;
}
.hero h1 {
  margin: 0 0 12px;
}
/* 标题改用透明 PNG 图形（1000×250），图形本身已带青蓝渐变，这里只控尺寸和投影 */
.hero h1.hero-title img {
  display: block;
  width: 380px;
  max-width: 100%;
  height: auto;
  filter: drop-shadow(0 2px 8px rgba(8, 24, 48, .45));
}
.hero-sub {
  margin: 0;
  font-size: 18px;
  color: rgba(255, 255, 255, .92);
  text-shadow: 0 1px 6px rgba(8, 24, 48, .5);
}

.panel {
  background: rgba(255, 255, 255, .92);
  border: 1px solid rgba(255, 255, 255, .65);
  border-radius: 16px;
  padding: 24px;
  margin-bottom: 24px;
  box-shadow: 0 8px 28px rgba(8, 24, 48, .1);
  transition: box-shadow .4s;
}
.panel:hover {
  box-shadow: 0 8px 28px rgba(8, 24, 48, .1),
              0 0 0 1px rgba(255, 255, 255, .55),
              0 0 16px rgba(190, 220, 235, .5),
              0 0 34px rgba(210, 232, 244, .35);
}
.panel-title {
  position: relative;
  margin: 0 0 16px;
  font-size: 18px;
  font-weight: 600;
  padding-left: 28px;
  color: var(--text);
}
/* 圣巢标志装饰：标题左侧图标 */
.panel-title::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 1.31em;
  height: 2em;
  background: url("img-monument.png?v=2") no-repeat center / contain;
}
.intro-text p {
  margin: 0 0 12px;
  font-size: 14px;
  line-height: 1.8;
  color: var(--text);
  overflow-wrap: break-word;
  word-break: break-word;
}
.intro-text p:last-child { margin-bottom: 0; }

.contact-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.contact-list li {
  margin: 0 0 10px;
  font-size: 14px;
  color: var(--text);
}
.contact-list li:last-child { margin-bottom: 0; }
.contact-list .k {
  color: var(--muted);
  margin-right: 8px;
}
.contact-list a {
  color: var(--accent-dark);
  text-decoration: underline;
}

/* 我的分享区块：标题与面板顶对齐 */
.panel .section-head {
  margin-top: 0;
}

/* 手机端：侧栏折叠到顶部，内容区全宽 */
@media (max-width: 768px) {
  .home {
    flex-direction: column;
    gap: 20px;
    padding: 24px 16px 48px;
  }
  .sidebar {
    position: static;
    flex: none;
    width: 100%;
  }
  .side-nav {
    flex-direction: row;
    justify-content: center;
    flex-wrap: wrap;
    gap: 6px;
  }
  .side-nav a {
    padding: 8px 14px;
    font-size: 14px;
  }
  .hero h1 { font-size: 36px; }
  .panel { padding: 20px 16px; }
}

/* === 管理后台（admin.html，Day 21 轻量版） === */
/* 管理页标题放大、副标题降透明度（仅在 admin 页覆盖 share-head/share-sub） */
.admin-page .share-head h1 {
  font-size: 34px;
}
.admin-page .share-head .share-sub {
  color: rgba(255, 255, 255, .55);
}
.admin-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}
.admin-tag {
  font-size: 14px;
  color: rgba(255, 255, 255, .75);
  text-shadow: 0 1px 6px rgba(8, 24, 48, .5);
}
.admin-tag b {
  color: #fff;
}
/* 退出登录：浅红描边 + 白底，和主按钮区分 */
.admin-logout {
  padding: 7px 16px;
  border: 1px solid rgba(224, 122, 122, .6);
  border-radius: 8px;
  background: #fff;
  color: #c96a6a;
  font-size: 13px;
  cursor: pointer;
  font-family: inherit;
  transition: background .15s, border-color .15s;
}
.admin-logout:hover {
  background: #fdf1f1;
  border-color: rgba(224, 122, 122, .85);
}
.admin-tip {
  margin: 0 0 16px;
  font-size: 13px;
  color: rgba(255, 255, 255, .62);
  text-shadow: 0 1px 5px rgba(8, 24, 48, .5);
}
/* 管理列表项：仿分享栏卡片（竖排，信息在上、缩略图在下），操作按钮放右上角 */
.admin-item {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 16px;
  padding-top: 46px;
  border-radius: 12px;
  border: 1px solid #e4edf2;
  background: #fff;
  align-items: stretch;
}
/* 管理列表专属缩略图（复用分享页卡片式大图，完整显示不裁切） */
.admin-thumb {
  width: 100%;
  max-height: 240px;
  object-fit: contain;
  border-radius: 8px;
  background: var(--accent-light);
}
/* 无图占位框：与缩略图同尺寸，撑住列对齐 */
.admin-thumb-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 120px;
  font-size: 22px;
  background: #f4f8fb;
  border: 1px dashed #cfd9e2;
  border-radius: 8px;
  box-sizing: border-box;
}
.admin-item .list-body { flex: none; min-width: 0; }
/* 标题行内的标签去掉基础 .tag 的 8px 上边距（在 flex 居中行里会错位） */
.admin-item-head .tag { margin-top: 0; }
/* 操作按钮组：绝对定位到卡片右上角 */
.admin-item .admin-actions {
  position: absolute;
  top: 10px;
  right: 10px;
  flex-direction: row;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px;
  margin-top: 0;
  z-index: 2;
}
/* 列表里的文档链接：蓝色可点，避免默认紫色/白色混淆 */
.admin-file-link {
  color: var(--accent-dark);
  word-break: break-all;
}
/* 文件名/外链简写：单行、超长省略号，鼠标悬停看全名 */
.admin-file-name {
  display: inline-block;
  max-width: 100%;
  vertical-align: bottom;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* 内联编辑表单：占满整行，落在缩略图/按钮下方（嵌在白色作品卡片内，用浅色底+深色字） */
.admin-edit-form {
  width: 100%;
  padding: 16px;
  border-radius: 10px;
  background: var(--accent-light);
  border: 1px solid rgba(47, 155, 214, .35);
  box-sizing: border-box;
}
/* 编辑表单内的标签和输入框：深蓝文字，浅色输入背景，确保在白卡片里清晰 */
.admin-edit-form .admin-field label {
  color: var(--accent-dark);
  text-shadow: none;
}
.admin-edit-form .admin-input {
  color: var(--accent-dark);
  background: #fff;
  border: 1px solid rgba(47, 155, 214, .4);
}
.admin-edit-form .admin-input::placeholder { color: rgba(29, 122, 184, .45); }
.admin-edit-form .admin-input:focus {
  border-color: var(--accent);
  background: #fff;
  box-shadow: 0 0 0 2px rgba(47, 155, 214, .15);
}
.admin-edit-form .admin-error {
  background: #fdeaea;
  color: #c0392b;
  text-shadow: none;
}
.admin-edit-actions {
  display: flex;
  gap: 10px;
  margin-top: 14px;
}
.admin-btn-save {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  font-weight: 600;
}
.admin-btn-save:hover {
  background: var(--accent-dark);
  border-color: var(--accent-dark);
}
.admin-btn-save:disabled {
  opacity: .6;
  cursor: not-allowed;
}

/* 上传按钮行：输入框 + 选择文件按钮横排（Day 22 上传功能） */
.admin-upload-row {
  display: flex;
  gap: 8px;
  align-items: stretch;
}
.admin-upload-row .admin-input {
  flex: 1;
  min-width: 0;
}
.admin-btn-upload {
  flex: 0 0 auto;
  white-space: nowrap;
  background: #fff;
  border: 1px solid #cfd9e2;
  color: var(--muted);
}
.admin-btn-upload:hover {
  background: #f4f8fb;
  border-color: #b9c6d0;
}
.admin-btn-upload:disabled {
  opacity: .6;
  cursor: not-allowed;
}

/* === 管理后台：新增表单 + 操作按钮（Day 22） === */
/* 新增表单：恢复原来的窄宽度（独立于加宽后的容器），居中显示 */
.admin-form {
  margin: 0 auto 24px;
  max-width: 640px;
  padding: 20px;
  border-radius: 16px;
  background: rgba(255, 255, 255, .85);
  border: 1px solid rgba(255, 255, 255, .9);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 6px 24px rgba(47, 155, 214, .12);
}
.admin-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.admin-field label {
  display: block;
  margin: 0 0 6px;
  font-size: 12px;
  font-weight: 600;
  color: var(--accent-dark);
  text-shadow: none;
}
.admin-field-wide { grid-column: 1 / -1; }
.admin-input {
  display: block;
  width: 100%;
  padding: 10px 12px;
  border: 1px solid rgba(47, 155, 214, .35);
  border-radius: 8px;
  font-size: 14px;
  color: var(--accent-dark);
  background: #fff;
  font-family: inherit;
  box-sizing: border-box;
}
.admin-input::placeholder { color: rgba(29, 122, 184, .42); }
.admin-input:focus {
  outline: none;
  border-color: var(--accent);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(47, 155, 214, .18), 0 0 12px rgba(47, 155, 214, .25);
}
select.admin-input option { color: #1a2b3c; }
textarea.admin-input { resize: vertical; min-height: 120px; }
.admin-submit {
  display: inline-block;
  margin-top: 18px;
  padding: 10px 24px;
  border: none;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: background .15s, box-shadow .2s;
}
.admin-submit:hover {
  background: var(--accent-dark);
  box-shadow: 0 0 16px rgba(47, 155, 214, .45);
}
.admin-submit:disabled { opacity: .6; cursor: not-allowed; }
.admin-error {
  margin: 10px 0 0;
  padding: 8px 12px;
  border-radius: 6px;
  background: #fdeaea;
  color: #c0392b;
  font-size: 13px;
  text-shadow: none;
}

.admin-item-head {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}
.admin-item-head .list-title { margin-bottom: 0; font-weight: 700; }
/* 简介文字降透明度，作为次要信息 */
.admin-desc { color: rgba(44, 62, 80, .6); }
.admin-meta { margin-top: 4px; font-size: 12px; overflow-wrap: anywhere; word-break: break-all; color: rgba(44, 62, 80, .55); }
/* id 编号：浅灰小字，弱化视觉权重 */
.admin-item .tag-id {
  background: rgba(180, 195, 205, .25);
  color: rgba(120, 140, 155, .9);
  font-weight: 400;
}
.tag-hidden {
  background: rgba(255, 200, 90, .2);
  color: #ffe0a3;
}
/* === 管理后台板块标签栏（顶部标签页切换） === */
.admin-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 16px;
}
.admin-tab {
  padding: 7px 16px;
  border: 1px solid rgba(47, 155, 214, .3);
  border-radius: 999px;
  background: rgba(255, 255, 255, .72);
  color: var(--accent-dark);
  font-size: 13px;
  cursor: pointer;
  font-family: inherit;
  transition: background .15s, border-color .15s, color .15s;
}
.admin-tab:hover {
  background: #eaf5fc;
  border-color: var(--accent);
}
.admin-tab.is-active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  font-weight: 600;
}

/* 板块空态占位 */
.admin-empty {
  padding: 24px 16px;
  border: 1px dashed rgba(47, 155, 214, .4);
  border-radius: 12px;
  background: rgba(255, 255, 255, .55);
  color: var(--accent-dark);
  font-size: 14px;
  text-align: center;
}

.admin-actions {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}
.admin-btn {
  padding: 6px 16px;
  border: 1px solid #cfd9e2;
  border-radius: 8px;
  background: #f4f8fb;
  color: #1a2b3c;
  font-size: 13px;
  cursor: pointer;
  font-family: inherit;
  transition: background .15s, border-color .15s;
}
.admin-btn:hover {
  background: #e3eef7;
  border-color: var(--accent);
}
/* 编辑：浅蓝底 */
.admin-btn-edit {
  background: #eaf5fc;
  border-color: rgba(47, 155, 214, .35);
  color: var(--accent-dark);
}
.admin-btn-edit:hover {
  background: #d6eafa;
  border-color: var(--accent);
}
/* 下架/上架：浅灰底 */
.admin-btn-toggle {
  background: #f0f2f4;
  border-color: #d5dbe0;
  color: #5a6670;
}
.admin-btn-toggle:hover {
  background: #e4e8eb;
  border-color: #bfc8cf;
}
/* 上移/下移：小巧的排序按钮 */
.admin-btn-move {
  padding: 6px 10px;
  font-size: 14px;
  line-height: 1;
  background: #f7fafc;
  border-color: #dbe4ea;
  color: var(--accent-dark);
}
.admin-btn-move:hover {
  background: #eaf5fc;
  border-color: var(--accent);
}
.admin-btn-move:disabled {
  opacity: .35;
  cursor: not-allowed;
  background: #f0f2f4;
  border-color: #e2e6ea;
}
.admin-btn-danger {
  border-color: #ecc8c8;
  background: #fdf3f3;
  color: #c07171;
}
.admin-btn-danger:hover {
  background: #f8e4e4;
  border-color: #e0a8a8;
}
/* 删除按钮的二次确认态：红底白字，提示再点一次 */
.admin-btn-danger.is-armed {
  background: #c0392b;
  border-color: #c0392b;
  color: #fff;
  font-weight: 600;
}

/* 管理后台卡片：窄屏（单列）时按钮可能换行，加大顶部留白防遮挡标题 */
@media (max-width: 600px) {
  .admin-item { padding-top: 84px; }
  .admin-item .admin-actions { max-width: calc(100% - 20px); }
}

/* === 电脑端字号提升：只放大文字，不改布局（防横向溢出） === */
@media (min-width: 769px) {
  /* 只提字号，布局宽度/间距保持原样，因此不会出现横向滚动条 */
  /* 注：.hero h1 现在是图片标题，字号对其无效，故不在此覆盖 */
  .subtitle { font-size: 19px; }
  .motto { font-size: 18px; }
  section h2 { font-size: 21px; }
  .work h1 { font-size: 31px; }
  .work section p.work-para { font-size: 18px; }
  .work-btn { font-size: 17px; }
  .card h3 { font-size: 19px; }
  .card p { font-size: 15px; }
  .section-head h2 { font-size: 21px; }
  .share-head h1 { font-size: 31px; }
  .share-sub { font-size: 17px; }
  .share-update { font-size: 14px; }
  .filter-btn { font-size: 17px; }
  .list-title { font-size: 19px; }
  .list-desc { font-size: 15px; }
  .tag { font-size: 14px; }
  .login-card h1 { font-size: 31px; }
  .login-card .login-sub { font-size: 17px; }
  .login-card label { font-size: 15px; }
  .login-card input { font-size: 17px; }
  .login-card .login-btn { font-size: 18px; }
  .login-error { font-size: 15px; }
  .login-hint { font-size: 14px; }
  .brand { font-size: 21px; }
  .nav-links a { font-size: 17px; }
  .intro p { font-size: 17px; }
  .col-title { font-size: 21px; }
  .about-list li { font-size: 17px; }
  .about-list .k { font-size: 17px; }
  .cat h3 { font-size: 18px; }
  .cat p { font-size: 14px; }
  .side-name { font-size: 26px; }
  .side-role { font-size: 15px; }
  .side-motto { font-size: 15px; }
  .side-nav a { font-size: 18px; }
  .side-login { font-size: 17px; }
  .hero-sub { font-size: 21px; }
  .panel-title { font-size: 21px; }
  .intro-text p { font-size: 17px; }
  .contact-list li { font-size: 17px; }
  .admin-page .share-head h1 { font-size: 40px; }
  .admin-tag { font-size: 17px; }
  .admin-logout { font-size: 15px; }
  .admin-tip { font-size: 15px; }
  .admin-thumb-empty { font-size: 26px; }
  .admin-field label { font-size: 14px; }
  .admin-input { font-size: 17px; }
  .admin-submit { font-size: 17px; }
  .admin-error { font-size: 15px; }
  .admin-item-head { font-size: 14px; }
  .admin-tab { font-size: 15px; }
  .admin-empty { font-size: 17px; }
  .admin-btn { font-size: 15px; }
  .admin-btn-move { font-size: 17px; }
}
/* === 电脑端字号提升 END === */

/* ============================================================
   九宫格（合影多图）+ 图片浮层大图（Day 24｜2026-10-23）
   ============================================================ */

/* 九宫格容器：CSS Grid，1 张占满、2~4 张两列、5~9 张三列（微信朋友圈式） */
.grid-nine {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
  margin-bottom: 8px;
}
.grid-nine[data-count="1"] { grid-template-columns: 1fr; }
.grid-nine[data-count="2"],
.grid-nine[data-count="4"] { grid-template-columns: repeat(2, 1fr); }

.grid-item {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 8px;
  cursor: pointer;
  background: #fff;
  transition: transform .12s ease;
}
.grid-item:hover { transform: scale(1.02); }
/* 单张图不裁切，按原图比例完整显示 */
.grid-nine[data-count="1"] .grid-item {
  aspect-ratio: auto;
  object-fit: contain;
  background: transparent;
}

/* 图片浮层大图：遮罩 + 居中大图 + 关闭按钮 */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(4, 10, 20, .92);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
/* hidden 属性必须能真正隐藏浮层（display:flex 会盖过 [hidden] 的默认 none） */
.lightbox[hidden] { display: none; }
.lightbox-img {
  max-width: 92vw;
  max-height: 88vh;
  object-fit: contain;
  border-radius: 8px;
  box-shadow: 0 8px 40px rgba(0, 0, 0, .6);
}
.lightbox-close {
  position: absolute;
  top: 16px;
  right: 20px;
  width: 44px;
  height: 44px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, .18);
  color: #fff;
  font-size: 30px;
  line-height: 1;
  cursor: pointer;
}
.lightbox-close:hover { background: rgba(255, 255, 255, .35); }

/* 管理后台：多图缩略图列表（含删除按钮） */
.admin-imgs-thumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}
.admin-imgs-item {
  position: relative;
  width: 64px;
  height: 64px;
}
.admin-imgs-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 6px;
  border: 1px solid rgba(0, 0, 0, .1);
}
.admin-imgs-del {
  position: absolute;
  top: -6px;
  right: -6px;
  width: 20px;
  height: 20px;
  border: none;
  border-radius: 50%;
  background: #e5484d;
  color: #fff;
  font-size: 14px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}
/* 封面角标（第一张自动为封面） */
/* 已废弃：封面改为独立 cover 字段，多图缩略图只保留删除按钮 */

