/* ========== 移动端（Vant 风格） ========== */
body.m-body {
  background: #f7f8fa; font-size: 16px; color: #323233;
  padding-bottom: calc(54px + env(safe-area-inset-bottom));
}

.m-header {
  position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 10px;
  height: 52px; padding: 0 12px; background: rgba(255, 255, 255, .96);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.m-logo { font-size: 17px; font-weight: 700; color: var(--m); flex: none; letter-spacing: .3px; }
.m-search { flex: 1; display: flex; gap: 8px; min-width: 0; }
.m-search input {
  flex: 1; min-width: 0; height: 34px; padding: 0 14px; border: 0;
  background: #f2f3f5; border-radius: var(--pill); font-size: 14px; color: var(--text);
}
.m-search input::placeholder { color: #b6b9c0; }
.m-search button {
  flex: none; height: 34px; padding: 0 16px; border-radius: var(--pill);
  background: linear-gradient(135deg, #4aa9ff, #1989fa); color: #fff; font-size: 14px;
  box-shadow: 0 4px 10px rgba(25, 137, 250, .22);
}
.m-pc { font-size: 13px; color: var(--muted); flex: none; }

.m-main { padding: 12px; }
.m-container { max-width: 768px; margin: 0 auto; }

/* ---------- 首页轮播 ---------- */
.m-banner-panel { padding: 0; overflow: hidden; }
.m-carousel { height: 172px; }
.m-carousel .carousel-caption { padding: 44px 104px 12px 14px; }
.m-carousel .carousel-caption strong { font-size: 17px; }
.m-carousel .carousel-caption em { font-size: 12.5px; }
.m-carousel .carousel-slide .cover-fallback { font-size: 24px; padding: 16px 24px; }
.m-carousel-dots { left: auto; right: 12px; bottom: 12px; display: flex; gap: 5px; }
.m-carousel-dots button {
  flex: none; width: 14px; height: 3px; padding: 0; border: 0; border-radius: 2px;
  background: rgba(255, 255, 255, .45);
}
.m-carousel-dots button.active { width: 20px; background: #fff; }

.m-panel {
  background: #fff; border-radius: var(--radius); padding: 14px;
  margin-bottom: 12px; box-shadow: 0 1px 4px rgba(0, 0, 0, .04);
}
.m-title { font-size: 17px; font-weight: 600; color: var(--text); letter-spacing: .2px; }
.m-panel-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.m-panel-head span, .m-panel-head a { font-size: 13px; color: var(--muted); }
.m-panel-head a:hover { color: var(--m); }

.m-cat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-top: 12px; }
.m-cat-grid a {
  padding: 12px 0; text-align: center; font-size: 14px; font-weight: 500; color: #3a7fc9;
  background: linear-gradient(135deg, #f0f7ff, #e8f3ff); border-radius: 10px;
  box-shadow: inset 0 0 0 1px rgba(25, 137, 250, .06); transition: all .2s;
}
.m-cat-grid a:active { background: var(--m-soft); transform: scale(.97); }

.m-hot-scroll {
  display: flex; gap: 12px; overflow-x: auto; padding: 12px 0 4px;
  scroll-snap-type: x proximity; -webkit-overflow-scrolling: touch;
}
.m-hot-scroll::-webkit-scrollbar { display: none; }
.m-hot-item {
  flex: none; width: 100px; display: flex; flex-direction: column; gap: 8px;
  text-align: center; scroll-snap-align: start;
}
.m-hot-item img, .m-hot-item .cover-fallback {
  width: 100px; height: 133px; object-fit: cover; border-radius: 8px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, .14);
}
.m-hot-item .cover-fallback { font-size: 14px; padding: 8px 6px; }
.m-hot-item strong {
  font-size: 13.5px; font-weight: 500; color: var(--text);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}

.m-newest li {
  display: flex; align-items: center; gap: 8px; padding: 10px 2px;
  border-bottom: 1px solid #f5f6f8; font-size: 14.5px;
}
.m-newest li:last-child { border-bottom: 0; }
.m-newest li a { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text); }
.m-newest span { color: var(--muted); font-size: 13px; width: 64px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.m-newest em {
  color: var(--m); font-style: normal; font-size: 12px; padding: 1px 7px;
  background: var(--m-soft); border-radius: var(--pill); flex: none;
}
.m-newest time { color: #b6b9c0; font-size: 12px; margin-left: auto; flex: none; }

.m-random-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 12px; }
.m-random-item { display: flex; flex-direction: column; gap: 6px; min-width: 0; text-align: center; }
.m-random-item img, .m-random-item .cover-fallback {
  width: 100%; aspect-ratio: 3 / 4; object-fit: cover; border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, .12);
}
.m-random-item .cover-fallback { display: flex; align-items: center; justify-content: center; font-size: 13px; padding: 8px 6px; }
.m-random-item strong {
  font-size: 13.5px; font-weight: 500; color: var(--text);
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}

.m-book-list { padding: 0; }
.m-book-item { display: flex; gap: 12px; padding: 12px 0; border-bottom: 1px solid #f5f6f8; }
.m-book-item:last-child { border-bottom: 0; }
.m-book-item img, .m-book-item .cover-fallback {
  width: 68px; height: 90px; object-fit: cover; border-radius: 6px; flex: none;
  box-shadow: 0 4px 10px rgba(0, 0, 0, .12);
}
.m-book-item .cover-fallback { font-size: 11px; padding: 6px 4px; }
.m-book-info { display: flex; flex-direction: column; min-width: 0; gap: 5px; }
.m-book-info strong { font-size: 16px; font-weight: 600; color: var(--text); }
.m-book-item .m-book-desc {
  font-size: 13.5px; color: var(--muted); display: -webkit-box;
  -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; line-height: 1.6;
}
.m-book-meta { font-size: 12.5px; color: #b6b9c0; }

.m-tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; display: flex;
  background: rgba(255, 255, 255, .97); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-top: 1px solid var(--line); box-shadow: 0 -1px 8px rgba(0, 0, 0, .04);
  padding-bottom: env(safe-area-inset-bottom);
}
.m-tabbar a {
  flex: 1; display: flex; flex-direction: column; align-items: center;
  padding: 7px 0 6px; font-size: 12px; color: #7d7e80; transition: color .2s;
}
.m-tabbar a.active { color: var(--m); font-weight: 600; }
.tab-ico { font-size: 17px; font-weight: 700; line-height: 1.2; margin-bottom: 2px; }
.m-tabbar em { font-style: normal; max-width: 76px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tab-dot {
  display: inline-block; width: 6px; height: 6px; margin-left: 3px;
  border-radius: 50%; background: #f56c6c; vertical-align: middle;
}

.m-crumb { font-size: 13px; color: #969799; padding: 2px 0 8px; }
.m-crumb span { margin: 0 4px; }
.m-h1 { font-size: 21px; font-weight: 600; margin: 4px 0 8px; color: var(--text); }
.m-sub { font-size: 13.5px; color: var(--muted); margin-bottom: 12px; }

.m-pagination { display: flex; justify-content: center; align-items: center; gap: 10px; padding: 16px 0; }
.m-pagination a, .m-pagination span {
  padding: 7px 16px; background: #fff; border: 1px solid var(--line);
  border-radius: var(--pill); font-size: 14px; color: var(--text-2);
}
.m-pagination a:active { background: var(--m-soft); color: var(--m); }
.m-pagination .disabled { color: #c8c9cc; }
.m-page-num { color: var(--muted) !important; border: 0 !important; background: none !important; }

.m-filter {
  background: #fff; border-radius: var(--radius); padding: 12px;
  margin-bottom: 12px; box-shadow: 0 1px 4px rgba(0, 0, 0, .04);
}
.m-filter-row { display: flex; gap: 10px; margin-bottom: 10px; }
.m-filter-row:last-child { margin-bottom: 0; }
.m-filter select, .m-filter input {
  flex: 1; min-width: 0; height: 38px; padding: 0 10px; border: 0;
  border-radius: var(--radius-sm); background: #f7f8fa; font-size: 14.5px; color: var(--text-2);
}
.m-filter button {
  flex: none; height: 38px; padding: 0 18px; border-radius: var(--radius-sm);
  background: linear-gradient(135deg, #4aa9ff, #1989fa); color: #fff; font-size: 14.5px;
  box-shadow: 0 4px 10px rgba(25, 137, 250, .22);
}
.m-search-hint {
  padding: 10px 12px; margin-bottom: 12px; border-radius: var(--radius);
  background: #eef6ff; border: 1px solid #c6e2ff; color: #1890ff;
  font-size: 13px; line-height: 1.5;
}
.m-hot-words { font-size: 13px; padding: 0 2px 12px; color: var(--muted); display: flex; flex-wrap: wrap; gap: 8px; }
.m-hot-words a {
  padding: 3px 12px; border-radius: var(--pill); background: #fff;
  color: var(--text-2); box-shadow: var(--shadow-sm);
}

/* 消息中心（复用 site.css 的 msg-item，次行布局） */
.msg-sub { display: flex; align-items: center; gap: 10px; margin-top: 6px; flex-wrap: wrap; }
.msg-sub time { font-size: 12px; color: var(--muted); flex: 1; }

.m-book-head {
  display: flex; gap: 14px; background: #fff; border-radius: var(--radius);
  padding: 14px; margin-bottom: 12px; box-shadow: 0 1px 4px rgba(0, 0, 0, .04);
}
/* 书籍头部操作行（点赞/下载），胶囊小按钮 */
.m-book-ops { display: flex; gap: 10px; margin: -4px 0 12px; }
.m-book-op {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 7px 16px; border-radius: var(--pill); font-size: 13px;
  border: 1px solid var(--line); background: #fff; color: var(--text-2);
}
.m-book-op:active { background: #f5f6f8; }
.m-book-cover { width: 108px; flex: none; }
.m-book-cover img, .m-book-cover .cover-fallback {
  width: 108px; height: 144px; object-fit: cover; border-radius: 8px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, .18);
}
.m-book-cover .cover-fallback { font-size: 16px; padding: 10px 8px; letter-spacing: 1px; }
.m-book-info2 { min-width: 0; }
.m-book-info2 h1 { font-size: 19px; font-weight: 600; margin-bottom: 10px; }
.m-book-info2 p { font-size: 13.5px; color: var(--muted); margin-bottom: 5px; }
.m-book-cat {
  color: #a8abb2 !important; line-height: 1.75;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.m-book-desc p { font-size: 15px; color: var(--text-2); line-height: 1.9; margin-top: 10px; }
.m-latest {
  display: flex; align-items: center; gap: 6px; background: #f0f7ff;
  border-radius: var(--radius); font-size: 13.5px; color: var(--muted);
}
.m-latest a { color: var(--m); flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.m-latest em { font-style: normal; color: #b6b9c0; flex: none; }

.m-chapter-group { margin-bottom: 6px; }
.m-chapter-group summary {
  font-size: 14.5px; color: var(--m); padding: 9px 0; list-style: none; cursor: pointer;
}
.m-chapter-group summary::-webkit-details-marker { display: none; }
.m-chapter-group summary::before { content: "›"; display: inline-block; margin-right: 6px; transition: transform .2s; }
.m-chapter-group[open] summary::before { transform: rotate(90deg); }
.m-chapter-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2px 6px; padding: 2px 0 8px; }
.m-chapter-list a {
  font-size: 13.5px; color: var(--text-2); overflow: hidden; text-overflow: ellipsis;
  white-space: nowrap; line-height: 2.4; padding: 0 6px; border-radius: 5px;
}
.m-chapter-list a:active { background: var(--m-soft); color: var(--m); }

.m-actionbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; display: flex; gap: 8px;
  padding: 8px 12px calc(8px + env(safe-area-inset-bottom));
  background: rgba(255, 255, 255, .97); backdrop-filter: blur(10px);
  box-shadow: 0 -2px 12px rgba(0, 0, 0, .06);
}
.m-actionbar .m-btn {
  flex: 1; text-align: center; height: 44px; line-height: 44px; border-radius: var(--pill);
  background: #f2f3f5; color: #646566; font-size: 16px; transition: transform .15s;
}
.m-actionbar .m-btn:active { transform: scale(.97); }
.m-actionbar .m-btn-primary {
  background: linear-gradient(135deg, #4aa9ff, #1989fa); color: #fff;
  box-shadow: 0 6px 16px rgba(25, 137, 250, .26);
}
.m-book-page { padding-bottom: 74px; }

/* ---------- 登录注册 ---------- */
.m-auth {
  max-width: 460px; margin: 8px auto 20px; background: #fff;
  border-radius: 14px; padding: 22px 16px; box-shadow: 0 2px 12px rgba(0, 0, 0, .05);
}
.m-auth .m-h1 { text-align: center; margin-bottom: 18px; }
.m-auth .auth-form button { width: 100%; padding: 12px 0; }
.m-auth .auth-alt { margin-top: 16px; }

/* ---------- 阅读页 ---------- */
.m-read-head {
  position: fixed; top: 0; left: 0; right: 0; z-index: 30; display: flex;
  align-items: center; gap: 8px; padding: 0 12px; height: 48px;
  background: var(--read-bg, #fdfcf9); backdrop-filter: blur(10px);
  color: var(--read-color, #333);
  box-shadow: 0 1px 8px rgba(0, 0, 0, .06); font-size: 14px; transition: transform .2s;
}
.m-read-head button, .m-read-head a { color: inherit; font-size: 14px; opacity: .85; }
.m-read-back { flex: none; padding: 4px 6px; margin-left: -6px; }
.m-read-title {
  position: absolute; left: 50%; transform: translateX(-50%);
  max-width: 46%; overflow: hidden;
  text-overflow: ellipsis; white-space: nowrap; font-weight: 500;
}
.m-read-head-tools { display: flex; gap: 10px; flex: none; margin-left: auto; }
.m-read-head-tools button, .m-read-head-tools a { padding: 4px 2px; }
.m-read {
  max-width: 768px; margin: 0 auto; padding: 64px 18px 132px;
  font-family: "Source Han Serif SC", "Noto Serif SC", "Songti SC", "SimSun", serif;
  font-size: var(--read-font, 21px); line-height: var(--read-line, 1.9);
  background: var(--read-bg, #fff); min-height: 100vh; color: var(--read-color, #222);
  letter-spacing: var(--read-letter, .2px);
}
.m-read h1 { font-size: 22px; font-weight: 600; margin-bottom: 10px; }
.m-read-meta { font-size: 13px; color: #999; margin-bottom: 20px; }
.m-read-content p { margin-bottom: 1em; text-indent: 2em; }
.m-read-tools { display: flex; gap: 10px; margin-top: 28px; font-size: 14px; }
.m-read-tools a, .m-read-tools span {
  flex: 1; text-align: center; padding: 10px 0; border: 1px solid rgba(128, 128, 128, .25);
  border-radius: var(--pill); color: inherit; background: rgba(128, 128, 128, .06);
}
.m-read-tools .disabled { opacity: .3; background: transparent; }

.m-readbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; display: flex;
  flex-direction: column;
  background: var(--read-bg, #fdfcf9); color: var(--read-color, #333);
  box-shadow: 0 -2px 12px rgba(0, 0, 0, .1);
  padding-bottom: env(safe-area-inset-bottom); transition: transform .2s;
}
.m-readbar-row { display: flex; align-items: center; width: 100%; }
.m-readbar a, .m-readbar button, .m-readbar span { flex: 1; text-align: center; color: inherit; }
.m-readbar-pager a, .m-readbar-pager span { padding: 11px 0; font-size: 15px; }
.m-readbar-pager em {
  flex: 0 0 32%; text-align: center; font-style: normal;
  font-size: 13px; opacity: .55;
}
.m-readbar-tools { border-top: 1px solid rgba(128, 128, 128, .15); }
.m-readbar-tools button, .m-readbar-tools a { padding: 10px 0; font-size: 14.5px; }
.m-readbar .disabled { opacity: .3; }
.m-read-settings {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 31;
  background: var(--read-bg, #fdfcf9); color: var(--read-color, #333);
  border-radius: 20px 20px 0 0;
  padding: 18px 16px calc(20px + env(safe-area-inset-bottom));
  box-shadow: 0 -4px 24px rgba(0, 0, 0, .15);
  max-height: 72vh; overflow-y: auto;
}
.m-read-settings[hidden], .m-read-catalog[hidden], .m-feedback-dialog[hidden] { display: none; }
.m-read-settings:not([hidden]), .m-read-catalog:not([hidden]) { animation: mSlideUp .28s ease-out; }
@keyframes mSlideUp { from { transform: translateY(100%); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
.setting-row { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.setting-row:last-child { margin-bottom: 0; }
.setting-row > span { flex: 0 0 40px; opacity: .6; font-size: 13px; }
.setting-control { flex: 1; display: flex; align-items: center; justify-content: flex-end; gap: 12px; }
.setting-control button {
  min-width: 64px; padding: 7px 14px; border-radius: 8px;
  border: 1px solid rgba(128, 128, 128, .3); background: rgba(128, 128, 128, .08);
  font-size: 14px; color: inherit;
}
.setting-control button:active { background: rgba(128, 128, 128, .18); }
.setting-value { min-width: 42px; text-align: center; font-style: normal; font-size: 14px; font-weight: 600; }
.m-read-settings .rs-themes { flex: 1; justify-content: flex-end; gap: 12px; }
.m-read-settings .rs-swatch { width: 34px; height: 34px; padding: 0; border-radius: 50%; border: 2px solid rgba(128, 128, 128, .25); }
.m-read-settings .rs-swatch.active { border-color: var(--m); box-shadow: 0 0 0 2px rgba(64, 158, 255, .25); }
.setting-actions { flex-wrap: wrap; justify-content: space-between; gap: 8px 4px; }
.setting-actions .link-btn { margin: 0; font-size: 13px; color: var(--m); }
.setting-reset { margin-top: 2px; }
.setting-reset button {
  width: 100%; padding: 10px 0; border-radius: var(--pill);
  background: rgba(128, 128, 128, .1); color: inherit; font-size: 14px;
}

/* 阅读页"更多"菜单 */
.m-read-more { padding: 10px 16px calc(16px + env(safe-area-inset-bottom)); }
.m-read-more .setting-row { margin-bottom: 8px; }
.m-more-item {
  display: block; width: 100%; padding: 12px 0; border: 0; border-radius: 10px;
  background: rgba(128, 128, 128, .1); color: inherit; font-size: 15px;
  text-align: center; text-decoration: none; box-sizing: border-box;
}
.m-more-item:active { background: rgba(128, 128, 128, .2); }

/* 阅读页评论弹层 */
.m-read-comments .catalog-list li.rc-item { display: block; padding: 12px 0; }
.m-read-comments .rc-head { display: flex; justify-content: space-between; align-items: center; font-size: 13px; }
.m-read-comments .rc-head time { color: #999; font-size: 12px; font-style: normal; }
.m-read-comments .rc-item > p { margin-top: 4px; font-size: 14px; }
.m-read-comments .rc-replies { margin-top: 6px; padding-left: 10px; border-left: 2px solid rgba(128, 128, 128, .25); }
.m-read-comments .rc-reply { font-size: 13px; opacity: .8; margin-top: 4px; }
.m-read-comments .rc-post { padding: 0 16px 10px; }
.m-read-comments .rc-login { font-size: 13px; color: #999; }
.m-read-comments .rc-login a { color: var(--m); }
.rc-form { display: flex; gap: 8px; align-items: flex-end; }
.rc-form textarea {
  flex: 1; min-width: 0; box-sizing: border-box; resize: none;
  padding: 8px 10px; border: 1px solid rgba(128, 128, 128, .3); border-radius: 8px;
  background: rgba(128, 128, 128, .06); font-size: 14px; color: inherit;
}
.rc-form .btn { flex: none; padding: 8px 16px; }
.rc-reply-form { margin-top: 8px; }
.rc-reply-btn {
  border: 0; background: none; color: #999; font-size: 12px;
  padding: 2px 6px; margin-right: 4px;
}
.rc-reply-btn:active { color: var(--m); }

/* ---------- 移动端章节目录弹层（主题跟随） ---------- */
.m-read-catalog {
  position: fixed; left: 0; right: 0; top: 30%; bottom: 0; z-index: 32;
  display: flex; flex-direction: column;
  background: var(--read-bg, #fff); color: var(--read-color, #222);
  border-radius: 20px 20px 0 0; box-shadow: 0 -8px 24px rgba(0, 0, 0, .16);
  padding-bottom: env(safe-area-inset-bottom);
}
.catalog-head { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px 10px; }
.catalog-head strong { font-size: 16px; }
.catalog-close { font-size: 22px; line-height: 1; opacity: .5; padding: 0 4px; }
.catalog-tools { display: flex; gap: 10px; padding: 0 16px 10px; }
.catalog-tools input {
  flex: 1; height: 36px; padding: 0 14px; border: 1px solid rgba(128, 128, 128, .3);
  border-radius: var(--pill); background: rgba(128, 128, 128, .08); font-size: 14px; color: inherit;
}
.catalog-tools button {
  flex: none; padding: 0 14px; height: 36px; border-radius: var(--pill);
  background: rgba(64, 158, 255, .15); color: var(--m); font-size: 14px;
}
.catalog-list { flex: 1; overflow-y: auto; padding: 0 16px 24px; }
.catalog-list li {
  display: flex; align-items: center; justify-content: space-between;
  border-bottom: 1px solid rgba(128, 128, 128, .15);
}
.catalog-list a {
  flex: 1; min-width: 0; padding: 12px 0; font-size: 15px; color: inherit;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.catalog-list li.current a { color: var(--m); font-weight: 600; }
.catalog-list em {
  flex: none; font-style: normal; font-size: 12px; padding: 1px 8px;
  border-radius: var(--pill); background: rgba(64, 158, 255, .15); color: var(--m);
}
.catalog-list .catalog-empty { justify-content: center; opacity: .55; font-size: 14px; padding: 30px 0; }

/* 反馈弹窗 */
.m-feedback-dialog {
  position: fixed; left: 16px; right: 16px; top: 50%; z-index: 40;
  transform: translateY(-50%);
  background: var(--read-bg, #fff); color: var(--read-color, #222);
  border-radius: 16px; padding: 18px 16px; box-shadow: 0 12px 40px rgba(0, 0, 0, .3);
  max-height: 80vh; overflow-y: auto;
}
.m-feedback-dialog h3 { font-size: 16px; text-align: center; margin-bottom: 14px; }
.m-feedback-dialog textarea {
  width: 100%; border: 1px solid rgba(128, 128, 128, .3); border-radius: 10px;
  background: rgba(128, 128, 128, .08); color: inherit; padding: 10px 12px;
  font-size: 14px; margin-top: 10px; resize: none;
}
.m-feedback-dialog .fb-type span { background: rgba(128, 128, 128, .12); color: inherit; }
.m-feedback-dialog .fb-type input:checked + span { background: rgba(64, 158, 255, .18); color: var(--m); box-shadow: inset 0 0 0 1px var(--m); }
.m-feedback-actions { display: flex; gap: 10px; margin-top: 14px; }
.m-feedback-actions button { flex: 1; padding: 10px 0; border-radius: var(--pill); font-size: 14px; }
.m-feedback-cancel { background: rgba(128, 128, 128, .12); color: inherit; }
.m-feedback-submit { background: var(--m); color: #fff; }
.m-feedback-mask { position: fixed; inset: 0; z-index: 39; background: rgba(0, 0, 0, .45); }
.m-feedback-mask[hidden] { display: none; }

body.read-bars-hidden .m-read-head { transform: translateY(-100%); }
body.read-bars-hidden .m-readbar { transform: translateY(100%); }

/* 阅读主题：工具栏/按钮均跟随主题变量，无需单独覆盖 */
body.read-theme-dark .catalog-list li.current a { color: #58a6ff; }
body.read-theme-dark .m-read-meta { color: #777; }

/* ---------- 用户中心 ---------- */
.m-profile { background: linear-gradient(135deg, #eef7ff, #fff 70%); flex-wrap: wrap; }
.m-profile-info { min-width: 0; flex: 1; }
.m-profile-stats { width: 100%; display: flex; gap: 24px; margin-top: 14px; padding-top: 12px; border-top: 1px solid rgba(64, 158, 255, .12); }
.m-profile-stats li { display: flex; flex-direction: column; gap: 2px; }
.m-profile-stats em { font-style: normal; font-size: 11px; color: var(--muted); }
.m-profile-stats strong { font-size: 14px; color: var(--text); }
.m-profile-info strong { font-size: 17px; }
.m-profile-info p { font-size: 13.5px; color: var(--muted); margin-top: 5px; }
.m-user-menu li { border-bottom: 1px solid #f5f6f8; }
.m-user-menu li:last-child { border-bottom: 0; }
.m-user-menu a { display: flex; align-items: center; gap: 8px; padding: 14px 2px; font-size: 16px; color: var(--text); }
.menu-arrow { margin-left: auto; color: #c8c9cc; font-style: normal; }
.m-logout { margin: 18px 0 24px; text-align: center; }
.m-logout button {
  width: 100%; padding: 12px 0; border-radius: var(--pill);
  background: #fff; color: #ee0a24; border: 1px solid #ffe1e1;
}

@media (min-width: 560px) {
  .m-cat-grid { grid-template-columns: repeat(6, 1fr); }
  .m-main { padding: 16px; }
}

/* ---------- 404 / 关站页 ---------- */
.not-found { padding: 46px 12px 30px; }
.not-found h1 { font-size: 52px; }
.not-found-tip { margin: 12px 0 18px; font-size: 14px; }
.not-found-search { max-width: 100%; margin-bottom: 18px; }
.not-found-search input, .not-found-search button { height: 40px; }
.not-found-links .btn { padding: 8px 16px; font-size: 14px; }
.not-found-cats { font-size: 13px; }
.closed-body { padding-bottom: 0; }
.closed-page { padding: 16px; }
.closed-card { padding: 34px 20px; }
.closed-card h1 { font-size: 19px; }

/* ---------- 禁用缩放 ----------
   iOS 聚焦字号 <16px 的输入框会自动放大页面，故移动端表单控件统一 16px；
   touch-action: manipulation 去掉双击放大。 */
body.m-body { touch-action: manipulation; }
body.m-body input, body.m-body textarea, body.m-body select { font-size: 16px; }

