/* ============ 深色玻璃拟态主题 ============ */
* { margin: 0; padding: 0; box-sizing: border-box; }
:root {
  --bg-0: #0a0e1a;
  --glass: rgba(255,255,255,.055);
  --glass-2: rgba(255,255,255,.085);
  --line: rgba(255,255,255,.10);
  --line-2: rgba(255,255,255,.17);
  --ink: #eef1f8;
  --ink-2: #a8b1c5;
  --ink-3: #6d7790;
  --brand-1: #6366f1;
  --brand-2: #8b5cf6;
  --brand-3: #22d3ee;
  --gold: #f5c86b;
  --shadow-sm: 0 2px 12px rgba(0,0,0,.28);
  --shadow-md: 0 14px 40px rgba(0,0,0,.42);
  --radius: 18px;
}
html { scroll-behavior: smooth; }
::selection { background: rgba(139,92,246,.35); }
body {
  font-family: "Inter", "PingFang SC", "HarmonyOS Sans SC", "Microsoft YaHei", -apple-system, "Segoe UI", sans-serif;
  background: var(--bg-0);
  color: var(--ink);
  line-height: 1.8;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  overflow-x: hidden;
}
body::before {
  content: "";
  position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(620px 620px at 14% -6%, rgba(99,102,241,.30), transparent 62%),
    radial-gradient(720px 720px at 96% -12%, rgba(34,211,238,.16), transparent 60%),
    radial-gradient(900px 900px at 50% 112%, rgba(139,92,246,.22), transparent 60%);
}
a { color: var(--brand-3); text-decoration: none; transition: color .2s ease; }
a:hover { color: #7dd3fc; }
.container { max-width: 1080px; margin: 0 auto; padding: 0 18px; }

/* ============ 悬浮吸顶毛玻璃头部 ============ */
.site-header {
  position: sticky; top: 14px; z-index: 100;
  width: calc(100% - 28px); max-width: 1080px; margin: 18px auto 30px;
  border-radius: 18px; padding: 14px 20px;
  background: rgba(13,19,34,.55);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  backdrop-filter: blur(20px) saturate(160%);
  border: 1px solid rgba(255,255,255,.12);
  box-shadow: 0 12px 40px rgba(0,0,0,.42);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 18px; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 13px; text-decoration: none; }
.brand-badge {
  width: 42px; height: 42px; flex: 0 0 auto;
  border-radius: 13px;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--brand-1), var(--brand-2) 55%, var(--brand-3));
  color: #fff;
  box-shadow: 0 8px 22px rgba(99,102,241,.45);
}
.brand-badge svg { width: 22px; height: 22px; }
.brand-text { display: flex; flex-direction: column; line-height: 1.25; }
.site-title { font-size: 19px; font-weight: 700; letter-spacing: .6px; color: var(--ink); }
.site-title a { color: inherit; }
.site-title a:hover { color: var(--brand-3); text-decoration: none; }
.site-desc { font-size: 12.5px; color: var(--ink-3); margin-top: 2px; letter-spacing: .3px; }
.header-nav { display: flex; gap: 6px; align-items: center; }
.header-nav a {
  font-size: 13.5px; color: var(--ink-2);
  padding: 7px 14px; border-radius: 999px;
  transition: all .2s ease;
}
.header-nav a:hover { color: #fff; background: rgba(255,255,255,.10); text-decoration: none; }
.header-nav a.active { color: #fff; background: linear-gradient(135deg, rgba(99,102,241,.9), rgba(139,92,246,.9)); box-shadow: 0 4px 14px rgba(99,102,241,.35); font-weight: 600; }

/* ============ 区块标题 ============ */
.section-head { text-align: center; margin: 10px 0 26px; }
.section-kicker { display: inline-block; font-size: 11px; letter-spacing: 5px; color: var(--gold); text-transform: uppercase; }
.section-title { font-size: 26px; font-weight: 800; margin-top: 6px; letter-spacing: 2px; color: var(--ink); }
.section-title::after { content: ""; display: block; width: 46px; height: 3px; border-radius: 2px; margin: 12px auto 0; background: linear-gradient(90deg, var(--gold), transparent); }

/* ============ 玻璃卡片通用 ============ */
.card, .article, .empty, .form-box, .login-box, .media-card {
  background: var(--glass);
  border: 1px solid var(--line);
  -webkit-backdrop-filter: blur(16px) saturate(150%);
  backdrop-filter: blur(16px) saturate(150%);
}

/* ============ 文章卡片 ============ */
.card { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; border-radius: 14px; padding: 15px 22px; margin-bottom: 12px; box-shadow: var(--shadow-sm); transition: transform .28s ease, box-shadow .28s ease, border-color .28s ease; animation: rise .5s ease both; }
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: rgba(139,92,246,.45); }
.card-title { flex: 1 1 220px; min-width: 0; font-size: 18px; font-weight: 700; letter-spacing: .2px; line-height: 1.4; }
.card-title a { color: var(--ink); }
.card-title a:hover { color: var(--brand-3); text-decoration: none; }
.card-meta { display: inline-flex; align-items: center; gap: 8px; color: var(--ink-3); font-size: 12.5px; margin: 0; white-space: nowrap; }
.card-meta::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 6px var(--gold); }
.card-author { color: var(--ink-2); }

.empty { border-radius: var(--radius); padding: 60px 20px; text-align: center; color: var(--ink-3); font-size: 15px; box-shadow: var(--shadow-sm); }

/* ============ 分页 ============ */
.pagination { display: flex; justify-content: center; align-items: center; gap: 10px; margin: 30px 0 10px; color: var(--ink-2); font-size: 14px; flex-wrap: wrap; }
.pagination a {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 8px 16px; border-radius: 999px;
  background: var(--glass); border: 1px solid var(--line);
  color: var(--ink-2); font-size: 13.5px; box-shadow: var(--shadow-sm);
  transition: all .2s ease;
}
.pagination a:hover { color: #fff; border-color: var(--brand-2); text-decoration: none; transform: translateY(-1px); }

/* ============ 文章详情 ============ */
.article { border-radius: 20px; padding: 42px 46px; box-shadow: var(--shadow-md); margin-top: 6px; animation: rise .5s ease both; }
.article h1 { font-size: 30px; font-weight: 800; letter-spacing: .3px; line-height: 1.4; margin-bottom: 10px; }
.article .meta { display: inline-flex; align-items: center; gap: 8px; color: var(--ink-3); font-size: 13.5px; margin-bottom: 24px; }
.article .meta::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 8px var(--gold); }
.article .content { color: var(--ink); font-size: 16.5px; line-height: 2; }
.article .content img { max-width: 100%; border-radius: 12px; margin: 8px 0; box-shadow: var(--shadow-sm); }
.back {
  display: inline-flex; align-items: center; gap: 6px;
  margin-top: 30px; padding: 9px 20px; border-radius: 999px;
  background: linear-gradient(135deg, var(--brand-1), var(--brand-2));
  color: #fff !important; font-size: 14px;
  box-shadow: 0 8px 20px rgba(99,102,241,.35);
  transition: all .2s ease;
}
.back:hover { transform: translateY(-1px); box-shadow: 0 10px 28px rgba(139,92,246,.5); text-decoration: none; }

/* ============ 页脚 ============ */
.site-footer { text-align: center; color: var(--ink-3); font-size: 13px; padding: 36px 0 42px; letter-spacing: .5px; }
.site-footer .gold { color: var(--gold); }

/* ============ 相册 / 视频 ============ */
.media-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 18px; }
.media-card { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm); transition: transform .25s ease, box-shadow .25s ease; margin: 0; animation: rise .5s ease both; }
.media-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); border-color: rgba(139,92,246,.45); }
.media-card img { width: 100%; height: 200px; object-fit: cover; display: block; background: rgba(255,255,255,.04); }
.media-card video { width: 100%; display: block; background: #05070d; aspect-ratio: 16 / 9; }
.media-card figcaption { padding: 14px 16px 16px; }
.media-title { font-size: 16px; font-weight: 700; color: var(--ink); margin-bottom: 4px; }
.media-desc { font-size: 13.5px; color: var(--ink-2); margin-bottom: 8px; }
.media-meta { font-size: 12.5px; color: var(--ink-3); display: inline-flex; align-items: center; gap: 6px; }
.media-meta::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 6px var(--gold); }

/* ============ 编辑器 / 正文媒体 ============ */
.editor-tools { display: flex; gap: 10px; align-items: center; margin-bottom: 10px; }
.editor-tools .msg { margin: 0; }
.inline-media { margin: 16px 0; text-align: center; }
.inline-media img { max-width: 100%; border-radius: 12px; box-shadow: var(--shadow-md); }
.inline-media video { width: 100%; max-width: 720px; border-radius: 12px; background: #05070d; display: block; margin: 0 auto; }

/* ============ 后台 ============ */
.admin-wrap { max-width: 1120px; margin: 30px auto; padding: 0 18px; }
.admin-nav {
  position: sticky; top: 14px; z-index: 100;
  display: flex; gap: 12px; align-items: center; flex-wrap: wrap; row-gap: 10px;
  background: rgba(13,19,34,.55);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  backdrop-filter: blur(20px) saturate(160%);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 16px; padding: 12px 18px;
  box-shadow: 0 12px 40px rgba(0,0,0,.42);
  margin-bottom: 22px;
}
.admin-nav .spacer { flex: 1; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 9px 18px; border-radius: 10px;
  background: linear-gradient(135deg, var(--brand-1), var(--brand-2));
  color: #fff; border: none; cursor: pointer; font-size: 14px; font-family: inherit;
  box-shadow: 0 6px 18px rgba(99,102,241,.35); transition: all .2s ease;
}
.btn:hover { transform: translateY(-1px); box-shadow: 0 8px 22px rgba(139,92,246,.5); text-decoration: none; }
.btn.ghost { background: rgba(255,255,255,.08); color: var(--ink-2); box-shadow: none; border: 1px solid var(--line); }
.btn.ghost:hover { background: rgba(255,255,255,.14); color: #fff; }
.btn.danger { background: linear-gradient(135deg,#ef4444,#f97316); box-shadow: 0 6px 18px rgba(239,68,68,.35); }
.btn.danger:hover { background: linear-gradient(135deg,#dc2626,#ef4444); }
.tab-btn.active { background: linear-gradient(135deg, rgba(99,102,241,.85), rgba(139,92,246,.85)); color: #fff !important; border-color: transparent; }
table { width: 100%; border-collapse: collapse; background: var(--glass); border-radius: 14px; overflow: hidden; box-shadow: var(--shadow-sm); border: 1px solid var(--line); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); }
th, td { padding: 13px 16px; border-bottom: 1px solid var(--line); text-align: left; font-size: 14px; }
th { background: rgba(255,255,255,.05); color: var(--ink-2); font-weight: 600; }
tr:last-child td { border-bottom: none; }
tr:hover td { background: rgba(255,255,255,.04); }
.form-box { border-radius: 16px; padding: 30px 34px; box-shadow: var(--shadow-sm); }
.form-box label { display: block; font-weight: 600; margin: 16px 0 7px; color: var(--ink); }
.form-box input[type=text], .form-box input[type=password], .form-box textarea {
  width: 100%; padding: 11px 14px; border: 1px solid var(--line-2); border-radius: 10px;
  font-size: 15px; font-family: inherit; background: rgba(255,255,255,.06); color: var(--ink);
  transition: border-color .2s ease, box-shadow .2s ease;
}
.form-box input:focus, .form-box textarea:focus { outline: none; border-color: var(--brand-2); box-shadow: 0 0 0 3px rgba(139,92,246,.25); background: rgba(255,255,255,.09); }
.form-box textarea { min-height: 320px; resize: vertical; }
.form-box .btn { margin-top: 18px; }
.login-box { max-width: 400px; margin: 90px auto; border-radius: 18px; padding: 40px; box-shadow: var(--shadow-md); }
.login-box h1 { font-size: 24px; margin-bottom: 20px; text-align: center; letter-spacing: 1px; }
.login-box label { display: block; font-weight: 600; margin: 14px 0 7px; color: var(--ink); }
.login-box input[type=text], .login-box input[type=password] {
  width: 100%; padding: 11px 14px; border: 1px solid var(--line-2); border-radius: 10px;
  font-size: 15px; font-family: inherit; background: rgba(255,255,255,.06); color: var(--ink);
}
.login-box input:focus { outline: none; border-color: var(--brand-2); box-shadow: 0 0 0 3px rgba(139,92,246,.25); background: rgba(255,255,255,.09); }
.msg { padding: 11px 16px; border-radius: 10px; margin: 14px 0; font-size: 14px; }
.msg.err { background: rgba(239,68,68,.14); color: #fca5a5; border: 1px solid rgba(239,68,68,.3); }
.msg.ok { background: rgba(16,185,129,.14); color: #6ee7b7; border: 1px solid rgba(16,185,129,.3); }

/* ============ 动画 ============ */
@keyframes rise { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }
.admin-media-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.admin-media-item { background: var(--glass); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; box-shadow: var(--shadow-sm); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); }
.admin-media-item img { width: 100%; height: 130px; object-fit: cover; display: block; }
.admin-media-item video { width: 100%; max-height: 150px; display: block; background: #05070d; }
.admin-media-info { padding: 10px 12px; font-size: 13.5px; color: var(--ink); }
.admin-media-item .btn { margin: 0 12px 12px; }
/* ============ 首页栏目卡片 ============ */
.cat-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 36px; }
.cat-card {
  display: flex; flex-direction: column; align-items: flex-start; gap: 7px;
  background: var(--glass); border: 1px solid var(--line); border-radius: 18px;
  padding: 24px 26px; text-decoration: none; color: var(--ink);
  -webkit-backdrop-filter: blur(16px) saturate(150%);
  backdrop-filter: blur(16px) saturate(150%);
  box-shadow: var(--shadow-sm);
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
  animation: rise .5s ease both;
}
.cat-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); border-color: rgba(139,92,246,.5); text-decoration: none; }
.cat-icon { font-size: 32px; line-height: 1; }
.cat-name { font-size: 20px; font-weight: 800; letter-spacing: 1px; }
.cat-desc { font-size: 13px; color: var(--ink-3); }
@media (max-width: 640px) { .cat-cards { grid-template-columns: 1fr; } }.cat-card.active { border-color: rgba(139,92,246,.7); box-shadow: 0 0 0 1px rgba(139,92,246,.35), var(--shadow-md); }
.cat-card.active .cat-name { background: linear-gradient(135deg, var(--brand-1), var(--brand-3)); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
/* ============ 面包屑 ============ */
.breadcrumb {
  display: flex; align-items: center; flex-wrap: wrap; gap: 8px;
  font-size: 13.5px; color: var(--ink-3);
  padding: 9px 18px; margin: 2px 0 22px;
  background: var(--glass); border: 1px solid var(--line); border-radius: 12px;
  -webkit-backdrop-filter: blur(14px) saturate(150%);
  backdrop-filter: blur(14px) saturate(150%);
  box-shadow: var(--shadow-sm);
}
.breadcrumb a { color: var(--ink-2); }
.breadcrumb a:hover { color: var(--brand-3); text-decoration: none; }
.breadcrumb .sep { color: var(--ink-3); }
.breadcrumb .current { color: var(--ink); font-weight: 600; }
/* ============ 修改密码表单 ============ */
#view-password .form-box { max-width: 540px; margin: 0 auto; }
.form-actions { display: flex; gap: 12px; align-items: center; margin-top: 18px; flex-wrap: wrap; }
.form-actions .msg { margin: 0; }
/* ============ 视频卡片点击播放 ============ */
.media-card.video-card { display: block; text-decoration: none; color: inherit; }
.video-thumb { position: relative; display: block; }
.video-thumb video { width: 100%; aspect-ratio: 16 / 9; background: #05070d; display: block; }
.play-btn {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
  width: 56px; height: 56px; border-radius: 50%;
  background: rgba(255,255,255,.92); color: #111;
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; padding-left: 5px;
  box-shadow: 0 8px 24px rgba(0,0,0,.45);
  transition: transform .2s ease, background .2s ease;
}
.video-card:hover .play-btn { transform: translate(-50%, -50%) scale(1.1); background: #fff; }

/* ============ 图片 / 视频 独立详情页 ============ */
.photo-detail, .video-detail {
  background: var(--glass); border: 1px solid var(--line); border-radius: 20px;
  padding: 30px; box-shadow: var(--shadow-md); text-align: center;
  -webkit-backdrop-filter: blur(16px) saturate(150%);
  backdrop-filter: blur(16px) saturate(150%);
  animation: rise .5s ease both;
}
.photo-stage { text-align: center; }
.photo-stage img { max-width: 100%; max-height: 76vh; border-radius: 14px; box-shadow: var(--shadow-md); }
.photo-original { display: inline-block; margin-top: 12px; font-size: 13px; color: var(--brand-3); }
.video-stage video { width: 100%; max-width: 960px; border-radius: 14px; background: #05070d; box-shadow: var(--shadow-md); display: block; margin: 0 auto; aspect-ratio: 16 / 9; }
.photo-info { margin-top: 22px; text-align: center; }
.photo-info h1 { font-size: 24px; font-weight: 800; }
.photo-info .meta { display: inline-flex; align-items: center; gap: 8px; color: var(--ink-3); font-size: 13.5px; margin: 8px 0 10px; }
.photo-info .meta::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 8px var(--gold); }
.photo-info .desc { color: var(--ink-2); }
/* ============ 栏目卡片最新内容预览 ============ */
.cat-preview { font-size: 12.5px; color: var(--ink-2); margin-top: 4px; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cat-preview::before { content: "最新 · "; color: var(--gold); }
.cat-photo-img, .cat-video-src { width: 100%; height: 130px; object-fit: cover; border-radius: 12px; margin-bottom: 10px; background: rgba(255,255,255,.05); display: block; }