/* ============================================================
   豆蛙无限 - 全站样式
   风格: 科技简约 (对标影视飓风布局, 豆蛙品牌青绿)
   双主题: 黑绿(默认/夜间) + 白绿(日间), body[data-theme]
   ============================================================ */
/* 品牌字体（Web Font，font-display:swap 首帧不阻塞；两套并存便于切换） */
/* 醉寒江行草（行草风） */
@font-face {
  font-family: 'YEFONTZuiHanJiangXingCao';
  src: url('/fonts/zui.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
/* 三极锦宋简体 粗（锦宋风） */
@font-face {
  font-family: 'SJjinsongcu';
  src: url('/fonts/jinsong.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
/* 豆蛙像素（Minecraft 方块风；8x8 等宽，自绘字模） */
@font-face {
  font-family: 'DouwaPixel';
  src: url('/fonts/douwa-pixel.woff2') format('woff2'),
       url('/fonts/douwa-pixel.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
:root, html[data-theme="dark"] {
  --bg: #121212;
  --bg-elev: #1a1a1d;
  --bg-hover: #1f1f23;
  --border: #2a2a2f;
  --border-soft: #222226;
  --text: #f2f2f4;
  --text-2: #a3a3a8;
  --text-3: #6d6d72;
  --brand: #00e6a0;
  --brand-dim: rgba(0, 230, 160, 0.12);
  --brand-border: rgba(0, 230, 160, 0.35);
  --danger: #ff4b40;
  --warn: #ffb020;
  --nav-bg: rgba(18, 18, 18, 0.78);
  --code-bg: #0c0c0e;
  --logo-filter: invert(1);
  --radius: 10px;
  --radius-lg: 16px;
  --nav-h: 60px;
  --maxw: 1200px;
  --font: 'SJjinsongcu', "SimSun", "NSimSun", "Songti SC", "STSong", "华文宋体", "Noto Serif CJK SC", "PingFang SC", "Microsoft YaHei", "SimHei", sans-serif;
  --font-mono: ui-monospace, "Cascadia Code", Consolas, Menlo, "Courier New", "PingFang SC", "Microsoft YaHei", "SimHei", "Noto Sans CJK SC", monospace;
}
/* 像素方块风（MC 风格）全局开关：数字/英文走像素字体，中文回退原字体 */
html[data-theme="dark"].font-pixel,
html[data-theme="light"].font-pixel {
  --font: 'DouwaPixel', 'SJjinsongcu', "SimSun", "Songti SC", "Noto Serif CJK SC", "PingFang SC", "Microsoft YaHei", sans-serif;
}

html[data-theme="light"] {
  --bg: #f4f6f7;
  --bg-elev: #ffffff;
  --bg-hover: #eef1f2;
  --border: #dfe3e5;
  --border-soft: #e7eaec;
  --text: #1f2326;
  --text-2: #5c6468;
  --text-3: #98a0a5;
  --brand: #00b37e;
  --brand-dim: rgba(0, 179, 126, 0.1);
  --brand-border: rgba(0, 179, 126, 0.35);
  --danger: #e03e30;
  --warn: #c98600;
  --nav-bg: rgba(255, 255, 255, 0.82);
  --code-bg: #f1f3f4;
  --logo-filter: none;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
.container { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; width: 100%; }
main { flex: 1; }

/* ============ 顶部导航 (滚动毛玻璃) ============ */
.site-nav {
  position: fixed; top: 0; left: 0; right: 0;
  height: var(--nav-h);
  z-index: 100;
  background: var(--nav-bg);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.site-nav.scrolled {
  border-bottom-color: var(--border-soft);
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.45);
}
.nav-inner {
  max-width: var(--maxw); margin: 0 auto; padding: 0 24px;
  height: 100%;
  display: flex; align-items: center; gap: 32px;
}
.nav-logo { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 1.15rem; letter-spacing: 0.5px; }
.nav-logo img { height: 30px; width: auto; filter: var(--logo-filter); }
.nav-links { display: flex; gap: 4px; flex: 1; }
.nav-links a {
  padding: 8px 14px; border-radius: 8px;
  color: var(--text-2); font-size: 0.95rem;
  transition: color 0.15s, background 0.15s;
}
.nav-links a:hover { color: var(--text); background: var(--bg-hover); }
/* 语言切换（中/EN） */
.nav-lang { display: inline-flex; align-items: center; gap: 2px; font-size: 0.82rem; margin-right: 6px; white-space: nowrap; }
.nav-lang a { color: var(--text-3); text-decoration: none; padding: 3px 7px; border-radius: 6px; font-weight: 600; }
.nav-lang a:hover { color: var(--brand); }
.nav-lang a.on { color: var(--brand); background: var(--brand-dim); }
.lang-sep { color: var(--text-3); opacity: 0.5; }
.nav-links a.active { color: var(--brand); }
/* VIP 徽章 */
.badge-vip {
  background: linear-gradient(135deg, rgba(255, 200, 60, 0.18), rgba(255, 150, 40, 0.14));
  color: #ffb020; border: 1px solid rgba(255, 180, 60, 0.45);
}
/* 圆形头像 */
.avatar-img {
  width: 30px; height: 30px; border-radius: 50%; object-fit: cover;
  border: 2px solid var(--brand-border); flex-shrink: 0;
}
.avatar-xs {
  width: 22px; height: 22px; border-radius: 50%; object-fit: cover;
  vertical-align: middle; margin-right: 6px; flex-shrink: 0;
}
.avatar-xs-text {
  display: inline-flex; align-items: center; justify-content: center;
  width: 22px; height: 22px; border-radius: 50%; margin-right: 6px;
  background: var(--brand-dim); color: var(--brand);
  font-size: 0.72rem; font-weight: 700; vertical-align: middle; flex-shrink: 0;
}
.who-avatar { display: inline-flex; align-items: center; }
.who-avatar .avatar-xs, .who-avatar .avatar-xs-text { margin-right: 4px; }
.comment-item .who { display: flex; align-items: center; gap: 2px; }
/* 个人中心头像 */
.avatar-row { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; }
.avatar-lg {
  width: 96px; height: 96px; border-radius: 50%; object-fit: cover;
  border: 3px solid var(--brand-border); box-shadow: 0 4px 18px rgba(0,0,0,.25); flex-shrink: 0;
}
.avatar-lg-text {
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--brand-dim); color: var(--brand);
  font-size: 2.4rem; font-weight: 800;
}
.avatar-form { display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
/* ============ 积分 / 通知 / 答题 ============ */
.nav-icon-link { display: inline-flex; align-items: center; gap: 3px; font-size: .95rem; color: var(--text-2); text-decoration: none; position: relative; }
.nav-icon-link:hover { color: var(--brand); }
.nav-icon-link #nav-pts { font-size: .78rem; font-weight: 700; }
.bell-badge {
  position: absolute; top: -6px; right: -10px; background: var(--danger); color: #fff;
  font-size: .62rem; font-weight: 700; border-radius: 10px; padding: 1px 5px; min-width: 16px; text-align: center;
}
.week-row { display: flex; gap: 6px; }
.week-cell { flex: 1; text-align: center; border: 1px solid var(--border-soft); border-radius: 10px; padding: 8px 0; background: var(--bg); }
.week-cell.week-ok { border-color: var(--brand-border); background: var(--brand-dim); }
.week-day { font-size: .7rem; color: var(--text-3); }
.week-dot { font-size: .9rem; color: var(--brand); }
.rank-row { display: flex; align-items: center; gap: 12px; padding: 9px 6px; border-bottom: 1px solid var(--border-soft); }
.rank-row:last-child { border-bottom: none; }
.rank-me { background: var(--brand-dim); border-radius: 8px; }
.rank-no { width: 26px; text-align: center; font-weight: 700; color: var(--text-3); }
.rank-no.rank-top { color: var(--warn); }
.rank-name { flex: 1; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rank-streak { font-size: .8rem; }
.rank-pts { font-size: .9rem; }
.notif-unread { background: var(--brand-dim); border-radius: 10px; }
.quiz-q { margin-bottom: 16px; }
.quiz-q-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.quiz-q-text { font-weight: 600; margin-bottom: 10px; }
.quiz-opt { display: flex; align-items: center; gap: 10px; border: 1px solid var(--border-soft); border-radius: 10px; padding: 9px 14px; margin-bottom: 8px; cursor: pointer; background: var(--bg); transition: border-color .15s; }
.quiz-opt:hover { border-color: var(--brand-border); }
.quiz-opt:has(input:checked) { border-color: var(--brand); background: var(--brand-dim); }
.quiz-opt-right { border-color: var(--brand); color: var(--brand); font-weight: 600; }
.nav-user { display: flex; align-items: center; gap: 12px; }
.nav-user .avatar {
  width: 32px; height: 32px; border-radius: 50%;
  background: var(--brand-dim); border: 1px solid var(--brand-border);
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; color: var(--brand); font-size: 0.9rem;
}
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 8px 18px; border-radius: 8px;
  font-size: 0.9rem; font-weight: 600;
  border: 1px solid var(--border);
  background: var(--bg-elev); color: var(--text);
  cursor: pointer; transition: all 0.15s;
  font-family: inherit;
}
.btn:hover { border-color: var(--brand-border); background: var(--bg-hover); }
.btn-primary { background: var(--brand); border-color: var(--brand); color: #08110d; }
.btn-primary:hover { background: #00ffb3; border-color: #00ffb3; }
.btn-ghost { background: transparent; }
.btn-danger { color: var(--danger); border-color: rgba(255, 75, 64, 0.4); }
.btn-danger:hover { background: rgba(255, 75, 64, 0.1); }
.btn-sm { padding: 5px 12px; font-size: 0.82rem; border-radius: 6px; }
.btn[disabled] { opacity: 0.5; cursor: not-allowed; }

/* ============ Hero ============ */
.hero {
  position: relative;
  padding: calc(var(--nav-h) + 72px) 0 72px;
  overflow: hidden;
  border-bottom: 1px solid var(--border-soft);
}
.hero-bg {
  position: absolute; inset: 0; z-index: -1;
  background-size: cover; background-position: center;
  opacity: 0.32;
  filter: saturate(0.85) contrast(1.05);
}
.hero-bg::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(18,18,18,0.82) 0%, rgba(18,18,18,0.55) 45%, var(--bg) 100%);
}
html[data-theme="light"] .hero-bg { opacity: 0.5; }
html[data-theme="light"] .hero-bg::after {
  background: linear-gradient(180deg, rgba(244,246,247,0.82) 0%, rgba(244,246,247,0.4) 45%, var(--bg) 100%);
}
.hero h1 {
  font-size: clamp(2rem, 5vw, 3.4rem);
  font-weight: 800; letter-spacing: -0.5px;
  line-height: 1.2; margin-bottom: 18px;
}
.hero h1 .accent { color: var(--brand); }
.hero .slogan { font-size: 1.1rem; color: var(--text-2); max-width: 640px; margin-bottom: 32px; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }

/* ============ 分区 ============ */
.section { padding: 64px 0; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 28px; }
.section-head h2 { font-size: 1.45rem; font-weight: 700; letter-spacing: -0.3px; }
.section-head .more { color: var(--text-3); font-size: 0.85rem; }
.section-head .more:hover { color: var(--brand); }

/* ============ 卡片 ============ */
.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 20px; }
.card {
  background: var(--bg-elev);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-lg);
  padding: 24px;
  transition: transform 0.18s, border-color 0.18s, background 0.18s;
}
.card:hover { transform: translateY(-3px); border-color: var(--brand-border); }
.card h3 { font-size: 1.05rem; margin-bottom: 10px; }
.card .desc { color: var(--text-2); font-size: 0.9rem; margin-bottom: 14px; }
.card .meta { color: var(--text-3); font-size: 0.78rem; }
.card-icon {
  width: 44px; height: 44px; border-radius: 12px;
  background: var(--brand-dim); border: 1px solid var(--brand-border);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.3rem; margin-bottom: 16px;
}
.card-media { border-radius: var(--radius-lg) var(--radius-lg) 0 0; margin: -24px -24px 18px; overflow: hidden; }
.card-media img { width: 100%; height: 170px; object-fit: cover; transition: transform 0.3s; }
.card:hover .card-media img { transform: scale(1.04); }
.card-link { display: block; height: 100%; }

/* ============ 列表行 ============ */
.row-list { border-top: 1px solid var(--border-soft); }
.row {
  display: flex; align-items: center; gap: 16px;
  padding: 16px 4px; border-bottom: 1px solid var(--border-soft);
  transition: background 0.12s;
}
.row:hover { background: var(--bg-hover); border-radius: 10px; }
.row-main { flex: 1; min-width: 0; }
.row-title { font-weight: 600; font-size: 1rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row-sub { color: var(--text-3); font-size: 0.8rem; margin-top: 4px; }
.badge {
  display: inline-block; padding: 2px 10px; border-radius: 999px;
  font-size: 0.72rem; font-weight: 600;
}
.badge-brand { background: var(--brand-dim); color: var(--brand); border: 1px solid var(--brand-border); }
.badge-gray { background: var(--bg-hover); color: var(--text-3); border: 1px solid var(--border); }
.badge-red { background: rgba(255,75,64,0.12); color: var(--danger); border: 1px solid rgba(255,75,64,0.4); }
.badge-gold { background: rgba(255,176,32,0.12); color: var(--warn); border: 1px solid rgba(255,176,32,0.4); }
.badge-blue { background: rgba(70,140,255,0.12); color: #6ea8ff; border: 1px solid rgba(70,140,255,0.35); }

/* ============ 表单 ============ */
.form-panel {
  max-width: 460px; margin: 0 auto;
  background: var(--bg-elev); border: 1px solid var(--border-soft);
  border-radius: var(--radius-lg); padding: 36px;
}
.form-panel.wide { max-width: 720px; }
.form-title { font-size: 1.4rem; font-weight: 700; margin-bottom: 6px; text-align: center; }
.form-sub { color: var(--text-3); font-size: 0.88rem; margin-bottom: 26px; text-align: center; }
.form-group { margin-bottom: 18px; }
.form-group label { display: block; font-size: 0.85rem; color: var(--text-2); margin-bottom: 7px; font-weight: 500; }
.form-group input[type="text"], .form-group input[type="password"], .form-group input[type="email"],
.form-group input[type="number"], .form-group select, .form-group textarea {
  width: 100%; padding: 11px 14px;
  background: var(--bg); border: 1px solid var(--border);
  border-radius: 8px; color: var(--text); font-size: 0.95rem;
  font-family: inherit; outline: none; transition: border-color 0.15s;
}
.form-group input:focus, .form-group select:focus, .form-group textarea:focus { border-color: var(--brand); }
.form-group textarea { resize: vertical; min-height: 120px; line-height: 1.6; }
.form-error {
  background: rgba(255, 75, 64, 0.1); border: 1px solid rgba(255, 75, 64, 0.35);
  color: var(--danger); padding: 10px 14px; border-radius: 8px;
  font-size: 0.88rem; margin-bottom: 16px;
}
.form-tip { text-align: center; color: var(--text-3); font-size: 0.85rem; margin-top: 18px; }
.form-tip a { color: var(--brand); }

/* ============ 页面头 ============ */
.page-head { padding: calc(var(--nav-h) + 40px) 0 8px; }
.page-head h1 { font-size: 1.7rem; font-weight: 700; letter-spacing: -0.4px; }
.page-head .sub { color: var(--text-2); font-size: 0.92rem; margin-top: 6px; }
.content-section { padding: 28px 0 64px; }

/* ============ 详情页 ============ */
.article { max-width: 860px; margin: 0 auto; }
.article h1.title { font-size: 2rem; font-weight: 800; line-height: 1.3; margin-bottom: 14px; }
.article .meta-row { display: flex; gap: 18px; color: var(--text-3); font-size: 0.85rem; padding-bottom: 20px; border-bottom: 1px solid var(--border-soft); margin-bottom: 26px; flex-wrap: wrap; align-items: center;}
.article .content { font-size: 1.02rem; line-height: 1.9; }
.article .content p { margin: 14px 0; }
.article .content h2 { font-size: 1.35rem; margin: 30px 0 12px; }
.article .content h3 { font-size: 1.15rem; margin: 24px 0 10px; }
.article .content h4 { font-size: 1.05rem; margin: 20px 0 8px; }
.article .content h5 { font-size: 1rem; margin: 16px 0 6px; color: var(--text-2); }
.article .content h6 { font-size: 0.92rem; margin: 14px 0 6px; color: var(--text-2); }
.article .content hr { border: none; border-top: 1px solid var(--border-soft); margin: 26px 0; }
.article .content .md-li { margin: 4px 0; }
.article .content .md-li::before { content: '· '; color: var(--brand); }
.article .content .md-img { color: var(--text-3); font-size: 0.9rem; margin: 10px 0; }
.article .content .md-q { border-left: 3px solid var(--brand); background: var(--brand-dim); padding: 8px 14px; border-radius: 0 8px 8px 0; margin: 12px 0; color: var(--text-2); }
.article .content pre {
  background: var(--code-bg); border: 1px solid var(--border-soft); border-radius: 10px;
  padding: 16px; overflow-x: auto; margin: 16px 0; font-size: 0.9rem;
  font-family: var(--font-mono); line-height: 1.6;
}
.article .content code { background: var(--code-bg); padding: 2px 6px; border-radius: 5px; font-size: 0.9em; font-family: var(--font-mono); }
/* 代码块折叠容器（论坛帖子/评论） */
.article .content .cb { margin: 16px 0; border: 1px solid var(--border-soft); border-radius: 10px; overflow: hidden; background: var(--code-bg); }
.article .content .cb-head {
  display: flex; justify-content: space-between; align-items: center; gap: 10px;
  padding: 5px 8px 5px 14px; background: var(--bg-elev);
  border-bottom: 1px solid var(--border-soft); font-size: 0.78rem; color: var(--text-3);
}
.article .content .cb-tag { font-family: var(--font-mono); letter-spacing: 0.2px; }
.article .content .cb-toggle {
  border: 1px solid var(--border); background: var(--bg); color: var(--text-2);
  border-radius: 6px; padding: 1px 12px; font-size: 0.75rem; cursor: pointer;
  font-family: inherit; line-height: 1.8;
}
.article .content .cb-toggle:hover { color: var(--brand); border-color: var(--brand-border); }
.article .content .cb pre { margin: 0; border: none; border-radius: 0; border-top: 1px solid var(--border-soft); }
.article .content .cb.collapsed pre { display: none; }
.article .content blockquote {
  border-left: 3px solid var(--brand); background: var(--brand-dim);
  padding: 10px 16px; border-radius: 0 8px 8px 0; margin: 16px 0; color: var(--text-2);
}
.article .content img { border-radius: 12px; margin: 14px 0; }
.article .content a { color: var(--brand); }
.article .content ul, .article .content ol { padding-left: 24px; margin: 12px 0; }
.article .content table { width: 100%; border-collapse: collapse; margin: 16px 0; }
.article .content td, .article .content th { border: 1px solid var(--border-soft); padding: 8px 12px; }

/* 评论区 */
.comments { margin-top: 34px; }
.comments h3 { font-size: 1.1rem; margin-bottom: 16px; }
.comment-item { padding: 14px 0; border-bottom: 1px solid var(--border-soft); }
.comment-item .who { display: flex; align-items: center; gap: 8px; font-size: 0.82rem; color: var(--text-3); margin-bottom: 6px; }
.comment-item .who b { color: var(--text); font-size: 0.9rem; }

/* ============ 表格 ============ */
.data-table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.data-table th {
  text-align: left; padding: 10px 12px; color: var(--text-3);
  font-weight: 500; font-size: 0.8rem; border-bottom: 1px solid var(--border);
}
.data-table td { padding: 12px; border-bottom: 1px solid var(--border-soft); vertical-align: middle; }
.data-table tr:hover td { background: var(--bg-hover); }

/* ============ 面板容器 ============ */
.panel {
  background: var(--bg-elev); border: 1px solid var(--border-soft);
  border-radius: var(--radius-lg); padding: 24px;
  margin-bottom: 20px;
}
.panel h3 { font-size: 1.02rem; margin-bottom: 16px; }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 14px; }
.stat {
  background: var(--bg); border: 1px solid var(--border-soft); border-radius: 12px;
  padding: 18px; text-align: center;
}
.stat .num { font-size: 1.7rem; font-weight: 800; color: var(--brand); }
.stat .lbl { color: var(--text-3); font-size: 0.8rem; margin-top: 4px; }

/* ============ 页脚 ============ */
.site-footer { border-top: 1px solid var(--border-soft); padding: 40px 0 48px; margin-top: 40px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 32px; margin-bottom: 28px; }
.footer-brand { font-weight: 800; font-size: 1.1rem; margin-bottom: 10px; display: flex; align-items: center; gap: 8px; }
.footer-brand img { height: 24px; filter: var(--logo-filter); }
.footer-desc { color: var(--text-3); font-size: 0.85rem; }
.footer-col h4 { font-size: 0.85rem; color: var(--text-2); margin-bottom: 12px; }
.footer-col a { display: block; color: var(--text-3); font-size: 0.85rem; margin-bottom: 8px; }
.footer-col a:hover { color: var(--brand); }
.footer-bottom { border-top: 1px solid var(--border-soft); padding-top: 20px; display: flex; justify-content: space-between; color: var(--text-3); font-size: 0.78rem; flex-wrap: wrap; gap: 10px; }

/* ============ 其他 ============ */
.tag { display: inline-block; font-size: 0.78rem; color: var(--text-3); background: var(--bg); border: 1px solid var(--border-soft); border-radius: 6px; padding: 2px 8px; margin-right: 6px; }
.muted { color: var(--text-3); }
.empty-tip { text-align: center; color: var(--text-3); padding: 48px 0; font-size: 0.92rem; }
.flex { display: flex; align-items: center; gap: 10px; }
.flex-between { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.flex-wrap { flex-wrap: wrap; }
.mt8 { margin-top: 8px; } .mt16 { margin-top: 16px; } .mt24 { margin-top: 24px; } .mt32 { margin-top: 32px; }
.mb8 { margin-bottom: 8px; } .mb16 { margin-bottom: 16px; } .mb24 { margin-bottom: 24px; }
.text-brand { color: var(--brand); }
.pill-input { display: flex; gap: 8px; }
.pill-input input { flex: 1; }

/* 403/404 */
.error-page { text-align: center; padding: 120px 24px; }
.error-page .code { font-size: 5rem; font-weight: 800; color: var(--brand); letter-spacing: -2px; }
.error-page .msg { color: var(--text-2); margin: 16px 0 28px; font-size: 1.05rem; }

/* ============ 小程序 · 算命系统 ============ */
.btn-lg { padding: 12px 26px; font-size: 1rem; }

/* ============ 文档作品 ============ */
.doc-media {
  background: linear-gradient(135deg, var(--bg-hover), var(--bg-elev));
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px;
}
.doc-media img { width: 100%; height: 170px; object-fit: cover; object-position: top center; display: block; }
.doc-thumb-lg { width: 76px; height: 76px; border-radius: 10px; object-fit: cover; border: 1px solid var(--border-soft); flex-shrink: 0; }
.doc-icon { font-size: 2.6rem; line-height: 1; filter: grayscale(.15); }
.doc-ext {
  font-size: 0.68rem; font-weight: 800; letter-spacing: 1px;
  padding: 2px 10px; border-radius: 4px; color: #fff;
}
.doc-ext-pdf { background: #e5484d; }
.doc-ext-doc, .doc-ext-docx { background: #2f6fed; }
.doc-ext-xls, .doc-ext-xlsx { background: #1f9d55; }
.doc-ext-ppt, .doc-ext-pptx { background: #e2711d; }
.doc-ext-tag { display: inline-block; margin-left: 8px; font-size: 0.68rem; padding: 2px 8px; border-radius: 4px; color: #fff; vertical-align: middle; }
.doc-panel { border: 1px solid var(--border-soft); border-radius: var(--radius-lg); overflow: hidden; background: var(--bg-elev); }
.doc-panel-main { display: flex; align-items: center; gap: 16px; padding: 22px; flex-wrap: wrap; }
.doc-big-icon { font-size: 2.6rem; }
.doc-info { flex: 1; min-width: 180px; }
.doc-file-name { font-weight: 700; font-size: 1.05rem; word-break: break-all; }
.doc-preview { width: 100%; height: 70vh; border: none; border-top: 1px solid var(--border-soft); background: #fff; }
.pillar-row { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; }
.pillar { background: var(--bg); border: 1px solid var(--border-soft); border-radius: 12px; padding: 10px 14px; text-align: center; min-width: 74px; }
.pillar-label { font-size: 0.75rem; color: var(--text-3); margin-bottom: 6px; }
.pillar-gan, .pillar-zhi { font-size: 1.45rem; font-weight: 700; line-height: 1.5; }
.pillar-wx { font-size: 0.68rem; color: var(--text-3); font-weight: 400; }
.wuxing-bar { display: flex; gap: 8px; justify-content: center; margin-top: 16px; flex-wrap: wrap; }
.wx-chip { background: var(--brand-dim); color: var(--brand); border: 1px solid var(--brand-border); border-radius: 20px; padding: 3px 14px; font-size: 0.85rem; font-weight: 600; }
.wx-empty { background: var(--bg-hover); color: var(--text-3); border-color: var(--border); }
.tarot-card, .lot-card { background: var(--bg); border: 1px solid var(--border-soft); border-radius: 16px; padding: 28px 20px; }
.tarot-name { font-size: 2rem; font-weight: 800; }
.tarot-pos { display: inline-block; margin-top: 8px; padding: 2px 14px; border-radius: 20px; font-size: 0.8rem; font-weight: 600; }
.pos-up { color: var(--brand); background: var(--brand-dim); }
.pos-dn { color: var(--danger); background: rgba(255, 75, 64, 0.12); }
.tarot-text, .lot-text { margin-top: 12px; font-size: 1.05rem; }
.lot-no { color: var(--text-3); font-size: 0.85rem; }
.lot-grade { font-size: 1.9rem; font-weight: 800; color: var(--warn); margin-top: 6px; }
/* 今天吃什么 */
.food-result { background: var(--bg); border: 1px solid var(--border-soft); border-radius: 16px; padding: 24px 16px; }
.food-label { font-size: 0.8rem; color: var(--text-3); }
.food-main { font-size: 2.2rem; font-weight: 800; margin: 8px 0 4px; color: var(--brand); }
.food-alts { color: var(--text-2); font-size: 0.9rem; margin-bottom: 6px; }
.food-groups { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 16px; margin-top: 14px; }
.food-cat { font-weight: 700; color: var(--text-2); margin-bottom: 8px; font-size: 0.9rem; }
.food-items { display: flex; flex-wrap: wrap; gap: 6px; }
.food-chip { background: var(--bg); border: 1px solid var(--border-soft); border-radius: 20px; padding: 3px 10px; font-size: 0.8rem; color: var(--text-2); }
/* 考研单词 */
.word-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 10px; }
.word-card { display: flex; gap: 12px; background: var(--bg-elev); border: 1px solid var(--border-soft); border-radius: 12px; padding: 14px 16px; }
.word-no { color: var(--text-3); font-size: 0.75rem; font-weight: 700; margin-top: 3px; }
.word-en { font-size: 1.15rem; font-weight: 700; }
.word-pos { color: var(--brand); font-size: 0.78rem; margin-right: 8px; font-weight: 600; }
.word-zh { color: var(--text-2); margin-top: 3px; }
/* 政治考点 */
.topic-core { background: var(--brand-dim); border-left: 3px solid var(--brand); border-radius: 0 8px 8px 0; padding: 12px 16px; margin-top: 12px; color: var(--text); }
/* 番茄钟 */
.pomo-modes { display: flex; gap: 8px; justify-content: center; margin-bottom: 18px; }
.pomo-mode {
  border: 1px solid var(--border); background: var(--bg); color: var(--text-2);
  border-radius: 20px; padding: 6px 18px; font-size: 0.88rem; cursor: pointer; font-weight: 600;
  transition: all 0.15s;
}
.pomo-mode:hover { color: var(--brand); border-color: var(--brand-border); }
.pomo-mode.on { background: var(--brand-dim); color: var(--brand); border-color: var(--brand-border); }
.pomo-ring-wrap { position: relative; width: 300px; height: 300px; margin: 0 auto; }
.pomo-ring { width: 100%; height: 100%; }
.ring-bg { fill: none; stroke: var(--border-soft); stroke-width: 10; }
.ring-fg { fill: none; stroke: var(--brand); stroke-width: 10; stroke-linecap: round; transition: stroke-dashoffset 0.25s linear; }
.pomo-center {
  position: absolute; inset: 0; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 6px;
}
.pomo-time { font-size: 3.4rem; font-weight: 800; letter-spacing: -1px; font-variant-numeric: tabular-nums; }
.pomo-mode-label { color: var(--text-3); font-size: 0.95rem; }
.pomo-controls { display: flex; gap: 10px; justify-content: center; margin-top: 22px; flex-wrap: wrap; }
.pomo-stats { display: flex; gap: 10px; justify-content: center; margin-top: 18px; color: var(--text-2); font-size: 0.9rem; flex-wrap: wrap; align-items: center; }
.pomo-stats b { color: var(--brand); font-size: 1.05rem; }
.stat-sep { opacity: 0.4; }
.pomo-settings { display: flex; gap: 14px; justify-content: center; margin-top: 18px; flex-wrap: wrap; color: var(--text-2); font-size: 0.85rem; align-items: center; }
.pomo-settings input { width: 62px; background: var(--bg); border: 1px solid var(--border); border-radius: 8px; color: var(--text); padding: 5px 8px; text-align: center; }
.pomo-toast {
  position: fixed; left: 50%; bottom: 40px; transform: translateX(-50%) translateY(8px);
  background: var(--bg-elev); border: 1px solid var(--brand-border); color: var(--brand);
  padding: 10px 22px; border-radius: 30px; font-size: 0.92rem; font-weight: 600;
  opacity: 0; pointer-events: none; transition: opacity 0.25s, transform 0.25s; z-index: 9999;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3);
}
.pomo-toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* 移动端 */
@media (max-width: 800px) {
  .nav-links { display: none; }
  .footer-grid { grid-template-columns: 1fr; }
  .row { flex-wrap: wrap; }
  .section { padding: 44px 0; }
}

/* 淡入过渡 */
.fade-in { animation: fadeIn 0.3s ease; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* ============ 双击图片全屏查看 ============ */
#dw-lightbox {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.94);
  cursor: zoom-out;
  animation: lbFade 0.18s ease;
  user-select: none;
  -webkit-user-select: none;
}
#dw-lightbox img {
  max-width: 94vw;
  max-height: 92vh;
  object-fit: contain;
  border-radius: 8px;
  box-shadow: 0 8px 60px rgba(0, 0, 0, 0.8);
  animation: lbZoom 0.18s ease;
}
.dw-lb-hint {
  position: absolute;
  bottom: 22px;
  left: 0;
  right: 0;
  text-align: center;
  color: rgba(255, 255, 255, 0.55);
  font-size: 0.8rem;
  pointer-events: none;
}
@keyframes lbFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes lbZoom { from { transform: scale(0.96); opacity: 0.4; } to { transform: scale(1); opacity: 1; } }

/* ============ 影视飓风式全屏主页 ============ */
.hero-mega { position: relative; height: 92vh; min-height: 560px; overflow: hidden; margin-top: -1px; }
.hero-mega-slides, .hero-slide { position: absolute; inset: 0; }
.hero-slide { background-size: cover; background-position: center; opacity: 0; transition: opacity 1.6s ease; }
.hero-slide.active { opacity: 1; }
.hero-mega-mask { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,.35) 0%, rgba(0,0,0,.55) 55%, rgba(18,18,18,.92) 100%); }
html[data-theme="light"] .hero-mega-mask { background: linear-gradient(180deg, rgba(0,0,0,.4) 0%, rgba(0,0,0,.55) 60%, rgba(244,246,247,.95) 100%); }
.hero-mega-content { position: relative; z-index: 2; height: 100%; display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center; color: #fff; }
.hero-kicker { letter-spacing: 4px; font-size: .95rem; opacity: .8; margin-bottom: 18px; }
.hero-mega-title { font-size: clamp(2.4rem, 6.5vw, 4.6rem); font-weight: 800; line-height: 1.18; letter-spacing: 2px; text-shadow: 0 4px 30px rgba(0,0,0,.5); }
.hero-mega-sub { margin-top: 18px; color: rgba(255,255,255,.75); font-size: 1.05rem; max-width: 640px; }
.hero-mega-content .btn-glass { background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.35); color: #fff; backdrop-filter: blur(8px); }
.hero-mega-content .btn-glass:hover { background: rgba(255,255,255,.22); }
.hero-dots { display: flex; gap: 8px; margin-top: 30px; }
.hero-dots .dot { width: 8px; height: 8px; padding: 0; border: 0; cursor: pointer; border-radius: 50%; background: rgba(255,255,255,.4); transition: all .3s; }
.hero-dots .dot.on { background: var(--brand); width: 26px; border-radius: 5px; }
.hero-scroll-hint { position: absolute; bottom: 18px; left: 50%; transform: translateX(-50%); color: rgba(255,255,255,.6); font-size: 1.4rem; animation: hero-bob 1.8s infinite; z-index: 2; }
@keyframes hero-bob { 0%,100% { transform: translate(-50%, 0); } 50% { transform: translate(-50%, 8px); } }

/* ============ 公告横幅 / 导航搜索 ============ */
.ann-bar { background: linear-gradient(90deg, var(--brand-dim), rgba(0,230,160,.04)); border-bottom: 1px solid var(--brand-border); position: relative; z-index: 5; }
.ann-inner { display: flex; align-items: center; gap: 10px; padding: 8px 0; font-size: .88rem; }
.ann-tag { font-size: 1rem; }
.ann-tag.ann-imp { color: var(--warn); }
.ann-link { flex: 1; color: var(--text); text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ann-link:hover { color: var(--brand); }
.ann-close { background: none; border: none; color: var(--text-3); cursor: pointer; font-size: .85rem; padding: 2px 6px; }
.ann-close:hover { color: var(--brand); }
.nav-search { display: flex; align-items: center; margin-right: 4px; }
.nav-search input { background: var(--bg); border: 1px solid var(--border); border-radius: 20px; padding: 6px 14px; width: 170px; font-size: .82rem; color: var(--text); outline: none; transition: all .2s; }
.nav-search input:focus { border-color: var(--brand); width: 210px; }
.nav-search button { background: none; border: none; cursor: pointer; font-size: .9rem; margin-left: -30px; }
@media (max-width: 900px) { .nav-search { display: none; } }

/* ============ 专栏 ============ */
.col-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 16px; }
.col-card { border: 1px solid var(--border-soft); border-radius: var(--radius-lg); overflow: hidden; background: var(--bg-elev); text-decoration: none; color: var(--text); display: flex; flex-direction: column; transition: transform .2s, border-color .2s; }
.col-card:hover { transform: translateY(-3px); border-color: var(--brand-border); }
.col-cover { height: 96px; display: flex; align-items: center; justify-content: center; font-size: 2.2rem; background: linear-gradient(135deg, var(--brand-dim), var(--bg)); }
.col-cover img { width: 100%; height: 100%; object-fit: cover; }
.col-body { padding: 12px 14px; }
.col-title { font-weight: 700; margin-bottom: 4px; }
.col-desc { color: var(--text-2); font-size: .82rem; height: 36px; overflow: hidden; }
.col-meta { color: var(--text-3); font-size: .76rem; margin-top: 8px; }
.chem-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chem-chip { border: 1px solid var(--border); background: var(--bg); color: var(--text-2); border-radius: 6px; padding: 4px 10px; font-family: var(--font-mono); font-size: .8rem; cursor: pointer; }
.chem-chip:hover { color: var(--brand); border-color: var(--brand-border); }

/* ============ 思维导图 ============ */
.mm-root { display: inline-block; background: linear-gradient(135deg, var(--brand), #00c48c); color: #04120c; font-weight: 800; padding: 12px 22px; border-radius: 999px; font-size: 1.15rem; margin: 10px auto; }
.mm-canvas { text-align: center; overflow-x: auto; padding: 26px 10px; }
.mm-branches { display: flex; justify-content: center; gap: 40px; flex-wrap: wrap; margin-top: 26px; position: relative; }
.mm-branch { max-width: 300px; }
.mm-node1 { border: 1.5px solid var(--brand-border); background: var(--brand-dim); color: var(--brand); font-weight: 700; padding: 8px 16px; border-radius: 12px; margin-bottom: 8px; }
.mm-sub { border-left: 2px dashed var(--border); padding-left: 12px; text-align: left; }
.mm-node2 { background: var(--bg-elev); border: 1px solid var(--border-soft); padding: 5px 10px; border-radius: 8px; margin: 5px 0; font-size: .88rem; }
.mm-node3 { display: inline-block; background: var(--bg); border: 1px solid var(--border-soft); font-size: .76rem; color: var(--text-2); border-radius: 6px; padding: 2px 8px; margin: 3px; }

/* ============ 趋势图 / 统计 ============ */
.trend-bars { display: flex; align-items: flex-end; gap: 8px; height: 150px; padding-top: 10px; }
.trend-col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 4px; height: 100%; justify-content: flex-end; }
.trend-bar { width: 70%; background: var(--brand); border-radius: 4px 4px 0 0; opacity: .85; min-height: 2px; }
.trend-day { font-size: .62rem; color: var(--text-3); }

/* ============ 双模编辑器 ============ */
.editor-mode-switch { display: inline-flex; border: 1px solid var(--border); border-radius: 10px; overflow: hidden; }
.mode-btn { border: none; background: var(--bg); color: var(--text-2); padding: 6px 16px; cursor: pointer; font-size: .85rem; }
.mode-btn.on { background: var(--brand); color: #04120c; font-weight: 700; }
.md-pane { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.md-pane textarea { width: 100%; min-height: 460px; background: var(--bg); border: 1px solid var(--border); border-radius: 10px; color: var(--text); padding: 14px; font-family: var(--font-mono); font-size: .88rem; line-height: 1.7; resize: vertical; outline: none; }
.md-pane textarea:focus { border-color: var(--brand); }
.md-preview { border: 1px solid var(--border-soft); border-radius: 10px; padding: 14px 18px; background: var(--bg-elev); min-height: 460px; overflow-y: auto; }
.rich-pane .ql-toolbar { border-radius: 10px 10px 0 0; background: var(--bg-elev); border-color: var(--border-soft); }
.rich-pane .ql-container { min-height: 420px; border-radius: 0 0 10px 10px; background: var(--bg-elev); border-color: var(--border-soft); font-size: 1rem; }
.rich-pane .ql-editor { min-height: 400px; }
.ql-editor img { max-width: 100%; border-radius: 8px; }
@media (max-width: 900px) { .md-pane { grid-template-columns: 1fr; } }/* ============ 公告横幅与 fixed 导航的定位修正 ============ */
.ann-bar { padding-top: var(--nav-h); margin-top: -1px; position: relative; z-index: 6; }
.ann-bar .ann-inner { padding: 7px 0; }
/* 登录态导航元素多：中屏收拢次要项，防挤压错乱 */
@media (max-width: 1180px) {
  .nav-user .badge { display: none; }
  .nav-user .avatar-img, .nav-user .avatar { display: none; }
}
@media (max-width: 1080px) {
  .nav-links, .nav-search { display: none; }
  .nav-user .btn-ghost { padding: 6px 10px; }
}/* ============ 导航防挤压（字竖排修复 / 瘦身版） ============ */
.nav-inner { gap: 18px; flex-wrap: nowrap; }
.nav-logo, .nav-links, .nav-user, .nav-search { flex-shrink: 0; }
.nav-links { flex: 1 1 auto; min-width: 0; overflow-x: auto; scrollbar-width: none; flex-wrap: nowrap; }
.nav-links::-webkit-scrollbar { display: none; }
.nav-links a { white-space: nowrap; }
.nav-user { flex-wrap: nowrap; gap: 8px; }
.nav-user > * { flex-shrink: 0; white-space: nowrap; }
.nav-user .avatar, .nav-user a.avatar { display: inline-flex; width: 32px; height: 32px; border-radius: 50%; background: var(--brand-dim); border: 1px solid var(--brand-border); align-items: center; justify-content: center; font-weight: 700; color: var(--brand); font-size: .9rem; text-decoration: none; }
.nav-settings { font-size: 1.05rem; }
.nav-search { display: flex; align-items: center; gap: 6px; flex-shrink: 0; }
.nav-search input { width: 170px; padding: 7px 12px; border-radius: 99px; border: 1px solid var(--border); background: var(--bg-hover); color: var(--text); outline: none; transition: width .2s, border-color .2s; }
.nav-search input:focus { width: 210px; border-color: var(--brand-border); }
.nav-search button { border: none; background: transparent; cursor: pointer; font-size: .95rem; padding: 6px; border-radius: 8px; }
.nav-search button:hover { background: var(--bg-hover); }
@media (max-width: 1350px) {
  .nav-search { display: none; }
}
@media (max-width: 1000px) {
  .nav-links { display: none; }
  .nav-logo { margin-right: auto; }
}/* hero 箭头 */
.hero-arrow { position: absolute; top: 50%; transform: translateY(-50%); z-index: 3; width: 46px; height: 46px; border-radius: 50%; border: 1px solid rgba(255,255,255,.3); background: rgba(0,0,0,.25); color: #fff; font-size: 1.6rem; line-height: 1; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: all .2s; }
.hero-arrow:hover { background: rgba(0,230,160,.25); border-color: var(--brand); }
.hero-prev { left: 18px; }
.hero-next { right: 18px; }
@media (max-width: 800px) { .hero-arrow { display: none; } }/* 作品附件 */
.att-grid { display: flex; flex-direction: column; gap: 8px; }
.att-file { display: flex; align-items: center; gap: 8px; border: 1px solid var(--border-soft); border-radius: 10px; padding: 8px 12px; background: var(--bg-elev); }
.att-file-main { display: flex; align-items: center; gap: 12px; flex: 1; min-width: 0; text-decoration: none; color: var(--text); }
.att-ico { font-size: 1.4rem; }
.att-file-info { display: flex; flex-direction: column; min-width: 0; }
.att-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .9rem; }
.att-meta { font-size: .72rem; color: var(--text-3); }
.att-img { display: inline-flex; flex-direction: column; width: 140px; border: 1px solid var(--border-soft); border-radius: 10px; overflow: hidden; background: var(--bg-elev); text-decoration: none; color: var(--text); }
.att-img img { width: 100%; height: 92px; object-fit: cover; }
.att-ph { height: 92px; display: flex; align-items: center; justify-content: center; font-size: 1.6rem; }
.att-name { padding: 4px 8px; }
@media (min-width: 700px) { .att-img-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); } }.att-img-box { position: relative; display: inline-flex; }
.att-del { position: absolute; top: 4px; right: 4px; }
.att-del .btn { padding: 1px 8px; font-size: .7rem; }

/* ============ 移动端导航（汉堡菜单，≤1080px 时替代被隐藏的 nav-links） ============ */
.nav-burger {
  display: none;
  align-items: center; justify-content: center;
  width: 38px; height: 38px; flex-shrink: 0;
  border-radius: 8px;
  border: 1px solid var(--border-soft);
  background: var(--bg-elev);
  color: var(--text);
  font-size: 1.25rem; line-height: 1;
  cursor: pointer;
}
.nav-burger:hover { color: var(--brand); border-color: var(--brand-border); }
.mobile-nav {
  display: none;
  position: fixed; top: var(--nav-h); left: 0; right: 0;
  z-index: 99;
  background: var(--nav-bg);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border-soft);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.35);
  padding: 10px 16px 16px;
  max-height: calc(100vh - var(--nav-h));
  overflow-y: auto;
}
.mobile-nav.open { display: block; }
.mobile-nav .nav-links { display: flex; flex-direction: column; gap: 2px; }
.mobile-nav a {
  display: block;
  padding: 12px 10px;
  border-radius: 8px;
  color: var(--text-2);
  font-size: 1rem;
  border-bottom: 1px solid var(--border-soft);
  text-decoration: none;
}
.mobile-nav a:last-child { border-bottom: none; }
.mobile-nav a:hover, .mobile-nav a.active { color: var(--brand); background: var(--bg-hover); }
.mobile-nav .nav-search { display: flex; margin-top: 10px; padding: 0 4px; }
.mobile-nav .nav-search input { width: 100%; min-width: 0; }
@media (max-width: 1080px) {
  .nav-burger { display: inline-flex; }
  .nav-inner { gap: 12px; padding: 0 14px; }
}

/* ============ 角色标签（名字左侧，全站内容作者通用） ============ */
.role-tag {
  display: inline-block; font-size: .62rem; font-weight: 700;
  padding: 1px 7px; border-radius: 99px; margin-right: 6px;
  vertical-align: 1px; letter-spacing: .5px; white-space: nowrap;
  border: 1px solid; line-height: 1.5;
}
.role-owner  { color: #2de0ff; background: rgba(45,224,255,.10); border-color: rgba(45,224,255,.45); }   /* 站长 青 */
.role-vip    { color: #ffd84d; background: rgba(255,216,77,.10); border-color: rgba(255,216,77,.45); }   /* VIP 金 */
.role-auth   { color: #7ab8ff; background: rgba(122,184,255,.10); border-color: rgba(122,184,255,.45); }  /* 授权用户 蓝 */
.role-admin  { color: #58e08a; background: rgba(88,224,138,.10); border-color: rgba(88,224,138,.45); }    /* 管理员 绿 */
.role-user   { color: var(--text-2); background: rgba(255,255,255,.05); border-color: var(--border); }    /* 普通用户 白/灰 */

/* ============ 作品互动 / 评论点赞 ============ */
.w-react, .c-like { transition: all .15s; }
.w-react.btn-primary { border-color: var(--brand-border); }
.w-react.btn-danger { border-color: rgba(255,75,64,.5); }
.c-like.active { background: var(--brand-dim); color: var(--brand); border-color: var(--brand-border); }
.c-like.active:hover { color: var(--brand); }
.w-fav { transition: all .15s; }
.w-fav.btn-primary { background: var(--brand-dim); color: var(--brand); border-color: var(--brand-border); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    scroll-behavior: auto !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}

/* ============ 白色工作台：小程序 / 站长管理 / TS3 点歌台 ============ */
body.light-workspace {
  --bg: #f7f8f8; --bg-elev: #fff; --bg-hover: #f1f4f2;
  --border: #dfe5e1; --border-soft: #e8ece9;
  --text: #1d2421; --text-2: #5d6a63; --text-3: #87928b;
  --brand: #00a977; --brand-dim: rgba(0,169,119,.10); --brand-border: rgba(0,169,119,.34);
  --nav-bg: rgba(255,255,255,.92); --code-bg: #f1f4f2; --logo-filter: none;
  background: var(--bg); color: var(--text);
}
body.light-workspace .site-nav { background: var(--nav-bg); border-bottom-color: var(--border-soft); box-shadow: 0 1px 0 rgba(20,35,27,.04); }
body.light-workspace .nav-logo img { width: 31px; height: 31px; border-radius: 8px; filter: none; }
body.light-workspace .site-footer { background: #fff; border-top-color: var(--border-soft); }
body.light-workspace .page-head.workspace-head { padding-top: calc(var(--nav-h) + 50px); padding-bottom: 24px; border-bottom: 1px solid var(--border-soft); }
.workspace-eyebrow { margin: 0 0 7px; color: var(--brand); font-size: .7rem; font-weight: 800; letter-spacing: .14em; }
body.light-workspace .workspace-head h1 { font-size: clamp(2.15rem, 4vw, 3.25rem); letter-spacing: -.055em; line-height: 1.08; }
body.light-workspace .workspace-content { padding-top: 24px; }
body.light-workspace .btn-primary { color: #fff; background: var(--brand); border-color: var(--brand); }
body.light-workspace .btn-primary:hover { background: #008c63; border-color: #008c63; }
body.light-workspace .card, body.light-workspace .panel, body.light-workspace .stat { box-shadow: 0 2px 8px rgba(23,40,29,.025); }

/* 小程序 */
.apps-intro { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 13px 16px; margin-bottom: 18px; border: 1px solid #d5eade; border-radius: 10px; background: #effaf5; color: #436257; font-size: .88rem; }
.apps-intro a { color: var(--brand); font-weight: 700; white-space: nowrap; }
.apps-grid { grid-template-columns: repeat(auto-fill, minmax(235px, 1fr)); gap: 14px; }
body.light-workspace .apps-grid .card { min-height: 174px; padding: 18px; border-radius: 12px; background: #fff; }
body.light-workspace .apps-grid .card:hover { transform: translateY(-2px); border-color: #abd8c4; box-shadow: 0 13px 26px rgba(21,65,43,.08); }
body.light-workspace .apps-grid .card-icon { width: 38px; height: 38px; margin-bottom: 13px; border: 0; border-radius: 9px; background: var(--brand-dim); color: var(--brand); font-size: 1.2rem !important; }
body.light-workspace .apps-grid .card h3 { margin-bottom: 6px; font-size: 1rem; }
body.light-workspace .apps-grid .card .desc { min-height: 42px; margin-bottom: 8px; font-size: .83rem; line-height: 1.6; }

/* 站长管理台 */
.owner-nav { display: flex; gap: 6px; flex-wrap: wrap; padding: 7px; margin-bottom: 18px; border: 1px solid var(--border-soft); border-radius: 10px; background: #fff; }
.owner-nav .btn { border-color: transparent; background: transparent; }
.owner-nav .btn-primary { box-shadow: none; }
body.light-workspace-owner .stat-grid { grid-template-columns: repeat(3, 1fr); gap: 12px; }
body.light-workspace-owner .stat { padding: 17px; border-radius: 12px; text-align: left; }
body.light-workspace-owner .stat .num { font-size: 1.85rem; color: var(--text); }
body.light-workspace-owner .stat .lbl { margin-top: 3px; }
.owner-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 14px; }
body.light-workspace-owner .panel { border-radius: 12px; padding: 19px; }
body.light-workspace-owner .stat-link { display: block; color: inherit; cursor: pointer; transition: transform .16s, border-color .16s, box-shadow .16s; }
body.light-workspace-owner .stat-link:hover { transform: translateY(-2px); border-color: #b7ddca; box-shadow: 0 10px 22px rgba(20,67,43,.08); }
body.light-workspace-owner .stat-link .lbl { display: flex; justify-content: space-between; align-items: center; }
body.light-workspace-owner .stat-link .lbl span { color: var(--brand); font-size: 1rem; opacity: 0; transform: translateX(-4px); transition: opacity .16s, transform .16s; }
body.light-workspace-owner .stat-link:hover .lbl span { opacity: 1; transform: none; }
.owner-view { min-height: 180px; transition: opacity .16s; }
.owner-view.owner-view-loading { opacity: .45; pointer-events: none; }

/* TS3 与点歌台 */
.ts3-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
body.light-workspace-ts3 .ts3-status-panel { border-color: #d5eade; background: linear-gradient(135deg,#effaf5,#fff 72%); }
body.light-workspace-ts3 .stat-grid { gap: 10px; }
body.light-workspace-ts3 .stat { padding: 15px; border-radius: 10px; text-align: left; }
body.light-workspace-ts3 .stat .num { color: var(--text); font-size: 1.7rem; }
body.light-workspace-ts3 .panel { border-radius: 12px; }
body.light-workspace-ts3 .music-workspace { margin-top: 14px; border-color: #cce8da; background: #fff; }
body.light-workspace-ts3 .pill-input { border-color: var(--border); background: #fff; }
body.light-workspace-ts3 #search-results > div:hover, body.light-workspace-ts3 #queue-list > div:hover { background: #f3faf6 !important; }
@media (max-width: 900px) {
  body.light-workspace .page-head.workspace-head { padding-top: calc(var(--nav-h) + 32px); }
  .apps-intro { align-items: flex-start; flex-direction: column; }
  body.light-workspace-owner .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .owner-grid, .ts3-grid { grid-template-columns: 1fr; }
  .owner-nav { flex-wrap: nowrap; overflow-x: auto; }
  .owner-nav .btn { white-space: nowrap; }
}

/* 作品集：白色素材库式陈列，保留豆蛙内容与权限流程。 */
body.light-workspace-works .works-head { padding-top: calc(var(--nav-h) + 58px); padding-bottom: 22px; }
body.light-workspace-works .works-head h1 { font-size: clamp(2.4rem, 5.4vw, 4.25rem); letter-spacing: -.07em; }
body.light-workspace-works .works-head .sub { max-width: 650px; font-size: .95rem; }
.works-actions { display: flex; align-items: center; justify-content: flex-end; gap: 7px; flex-wrap: wrap; }
body.light-workspace-works .works-content { padding-top: 20px; }
body.light-workspace-works .works-filter { margin-bottom: 24px; padding: 0 0 15px; border: 0; border-bottom: 1px solid var(--border-soft); border-radius: 0; background: transparent; }
body.light-workspace-works .works-filter .btn { padding: 6px 0; margin-right: 18px; border: 0; border-radius: 0; background: transparent; color: var(--text-3); }
body.light-workspace-works .works-filter .btn:hover { color: var(--text); }
body.light-workspace-works .works-filter .btn-primary { color: var(--brand); box-shadow: none; }
.material-grid { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 16px; }
body.light-workspace-works .material-card { padding: 13px; border-radius: 10px; background: #fff; box-shadow: none; }
body.light-workspace-works .material-card:hover { transform: translateY(-2px); border-color: #b8dfcc; box-shadow: 0 14px 28px rgba(18,61,40,.08); }
body.light-workspace-works .material-card .card-media { margin: -13px -13px 14px; border-radius: 9px 9px 0 0; background: #edf1ef; }
body.light-workspace-works .material-card .card-media img { height: 208px; transition: transform .28s ease; }
body.light-workspace-works .material-card:hover .card-media img { transform: scale(1.025); }
body.light-workspace-works .material-card h3 { margin: 0 0 6px; font-size: 1rem; line-height: 1.45; letter-spacing: -.015em; }
body.light-workspace-works .material-card .desc { display: -webkit-box; overflow: hidden; min-height: 39px; margin-bottom: 11px; color: var(--text-2); font-size: .81rem; line-height: 1.55; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
body.light-workspace-works .material-card .meta { padding-top: 9px; border-top: 1px solid var(--border-soft); }
body.light-workspace-works .material-card .badge-gray { background: #f2f4f3; color: #627068; border-color: #e1e7e3; }
body.light-workspace-works .material-card .card-actions { display: flex; flex-wrap: wrap; gap: 6px; padding-top: 10px; border-top-color: var(--border-soft); }
@media (max-width: 720px) {
  body.light-workspace-works .works-head { padding-top: calc(var(--nav-h) + 34px); }
  body.light-workspace-works .works-head h1 { font-size: 2.45rem; }
  .works-actions { justify-content: flex-start; }
  body.light-workspace-works .works-filter { overflow-x: auto; flex-wrap: nowrap; }
  body.light-workspace-works .works-filter .btn { white-space: nowrap; margin-right: 15px; }
  .material-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  body.light-workspace-works .material-card { padding: 9px; }
  body.light-workspace-works .material-card .card-media { margin: -9px -9px 10px; }
  body.light-workspace-works .material-card .card-media img { height: 148px; }
  body.light-workspace-works .material-card h3 { font-size: .9rem; }
  body.light-workspace-works .material-card .desc { display: none; }
}
