/* ==========================================================
 * base.css - 站点基础样式（变量 / 布局 / 组件）
 * 主色沿用参考站：青 #03c8d4 + 金 #fbb715
 * ========================================================== */

:root {
  --brand: #22d3ee;
  --brand-dark: #0891b2;
  --brand-soft: #0f2f36;
  --gold: #fbb715;
  --gold-dark: #e0a300;
  --gold-soft: #2b2312;
  --danger: #ff5b5b;
  --purple: #8b5cf6;

  --ink: #e8eaed;
  --text: #a2adb8;
  --muted: #6b7684;
  --line: #262c36;
  --line-strong: #333b47;
  --bg: #0d1017;
  --card: #161b24;

  --radius: 10px;
  --radius-sm: 6px;
  --shadow: 0 2px 12px rgba(0, 0, 0, .35);
  --shadow-hover: 0 8px 28px rgba(0, 0, 0, .5);

  --header-h: 64px;
  --container: 1200px;
  --font: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei",
          "Hiragino Sans GB", "Helvetica Neue", Arial, sans-serif;
}

/* ---------- reset ---------- */
* { box-sizing: border-box; }
html, body, div, span, h1, h2, h3, h4, h5, h6, p, a, img, ul, ol, li,
dl, dt, dd, form, input, textarea, button, section, header, footer, nav,
article, aside, figure, figcaption { margin: 0; padding: 0; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; 
  overflow-x: clip;
}
body {
  overflow-x: clip;
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.7;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; transition: color .2s; }
a:hover { color: var(--brand); }
ul, ol { list-style: none; }
img { max-width: 100%; display: block; border: 0; vertical-align: middle; }
input, textarea, button, select { font-family: inherit; font-size: inherit; outline: none; }
button { cursor: pointer; border: 0; background: none; }
h1, h2, h3, h4, h5, h6 { font-weight: 600; color: var(--ink); line-height: 1.4; }

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 16px;
}
.clearfix::after { content: ''; display: block; clear: both; }

/* ---------- 通用按钮 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 40px;
  padding: 0 22px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 500;
  transition: all .25s;
  white-space: nowrap;
}
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-dark); color: #fff; transform: translateY(-1px); }
.btn-gold { background: linear-gradient(135deg, var(--gold), #ffd34d); color: #6b4b00; font-weight: 600; }
.btn-gold:hover { color: #6b4b00; transform: translateY(-1px); box-shadow: 0 6px 18px rgba(251, 183, 21, .4); }
.btn-ghost { background: transparent; color: var(--brand); border: 1px solid var(--brand); }
.btn-ghost:hover { background: var(--brand); color: #fff; }
.btn-block { width: 100%; }
.btn-lg { height: 48px; font-size: 15px; padding: 0 32px; }

/* ---------- 通用标签 ---------- */
.badge {
  display: inline-block;
  padding: 1px 7px;
  border-radius: 4px;
  font-size: 11px;
  line-height: 18px;
  font-weight: 500;
  vertical-align: middle;
}
.badge-vip { background: linear-gradient(135deg, #fbb715, #ff9500); color: #fff; }
.badge-free { background: #5cb85c; color: #fff; }
.badge-new { background: var(--danger); color: #fff; }
.badge-tag { background: var(--brand-soft); color: var(--brand-dark); }
.badge-custom { background: linear-gradient(135deg, #8b5cf6, #c084fc); color: #fff; }
.badge-hot { background: #ff5b5b; color: #fff; }

.price-tag {
  font-size: 15px;
  font-weight: 700;
  color: var(--danger);
}
.price-tag.free { color: #5cb85c; }
.price-tag .sym { font-size: 12px; }

/* ==========================================================
 * 顶部 Header
 * ========================================================== */
.header {
  position: sticky;
  top: 0;
  z-index: 1000;
  height: var(--header-h);
  background: var(--card);
  border-bottom: 1px solid var(--line);
}
.header .container {
  display: flex;
  align-items: center;
  height: var(--header-h);
  gap: 16px;
}
.logo {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  font-size: 18px;
  font-weight: 700;
  color: var(--ink);
}
.logo img { height: 32px; width: auto; }
.logo-text { display: flex; flex-direction: column; line-height: 1.2; }
.logo-text b { font-size: 16px; color: var(--ink); }
.logo-text span { font-size: 11px; color: var(--muted); font-weight: 400; }

/* 主导航 */
.nav-main {
  display: flex;
  align-items: center;
  flex: 1;
  height: var(--header-h);
  gap: 2px;
  overflow: hidden;
}
.nav-main > li { position: relative; height: var(--header-h); }
.nav-main > li > a {
  display: flex;
  align-items: center;
  height: var(--header-h);
  padding: 0 9px;
  font-size: 13.5px;
  color: var(--ink);
  white-space: nowrap;
}
.nav-main > li > a:hover,
.nav-main > li:hover > a { color: var(--brand); }
.nav-main > li.current-menu-item > a { color: var(--brand); font-weight: 600; }
.nav-main > li.current-menu-item > a::after {
  content: '';
  position: absolute;
  left: 13px; right: 13px; bottom: 0;
  height: 2px;
  background: var(--brand);
}
.nav-main .ico { margin-right: 4px; font-size: 13px; }

/* 二级菜单 */
.nav-main .sub-menu {
  display: none;
  position: absolute;
  top: var(--header-h);
  left: 0;
  min-width: 160px;
  background: var(--card);
  border: 1px solid var(--line);
  border-top: 0;
  border-radius: 0 0 var(--radius-sm) var(--radius-sm);
  box-shadow: var(--shadow);
  padding: 6px 0;
}
.nav-main li:hover .sub-menu { display: block; }
.nav-main .sub-menu li a {
  display: block;
  padding: 8px 16px;
  font-size: 13px;
  color: var(--text);
  white-space: nowrap;
}
.nav-main .sub-menu li a:hover { background: var(--brand-soft); color: var(--brand-dark); }

/* 右侧操作区 */
.nav-right {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.nav-right .nav-vip a {
  display: inline-flex;
  align-items: center;
  height: 32px;
  padding: 0 11px;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--gold), #ff9500);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
}
.nav-right .nav-vip a:hover { color: #fff; opacity: .9; }
.nav-right .nav-search a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px; height: 32px;
  border-radius: 50%;
  color: var(--text);
  font-size: 15px;
}
.nav-right .nav-search a:hover { background: var(--bg); color: var(--brand); }
.nav-right .nav-login a {
  font-size: 13px;
  color: var(--text);
  padding: 0 4px;
}
.nav-right .nav-login a:hover { color: var(--brand); }
.nav-right .nav-login .sep { color: var(--line-strong); }

/* 汉堡按钮（移动端） */
.nav-toggle {
  display: none;
  width: 36px; height: 36px;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  color: var(--ink);
  font-size: 20px;
}
.nav-toggle:hover { background: var(--bg); }

/* 移动端抽屉 */
.mobile-mask {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, .45);
  z-index: 1090;
}
.mobile-mask.show { display: block; }
.mobile-nav {
  position: fixed;
  top: 0; right: 0;
  width: 78%;
  max-width: 300px;
  height: 100%;
  background: var(--card);
  z-index: 1100;
  transform: translateX(100%);
  transition: transform .28s ease;
  overflow-y: auto;
  padding-bottom: 30px;
}
.mobile-nav.open { transform: translateX(0); }
.mobile-nav .m-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-h);
  padding: 0 16px;
  border-bottom: 1px solid var(--line);
  font-size: 15px;
  font-weight: 600;
  color: var(--ink);
}
.mobile-nav .m-close { font-size: 22px; color: var(--muted); line-height: 1; }
.mobile-nav ul li a {
  display: block;
  padding: 13px 16px;
  font-size: 14px;
  color: var(--ink);
  border-bottom: 1px solid var(--line);
}
.mobile-nav ul li ul li a {
  padding-left: 32px;
  font-size: 13px;
  color: var(--text);
  background: var(--bg);
}
.mobile-nav .m-actions {
  display: flex;
  gap: 10px;
  padding: 16px;
}
.mobile-nav .m-actions .btn { flex: 1; }

/* ==========================================================
 * 首页 Banner 轮播
 * ========================================================== */
.banner-slider { padding: 20px 0 4px; }
.banner-slider .container {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 14px;
}
.slider-left {
  position: relative;
  height: 300px;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--line-strong);
}
.slider-track { position: relative; width: 100%; height: 100%; }
.slide-item {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity .6s ease;
  background-size: cover;
  background-position: center;
}
.slide-item.active { opacity: 1; }
.slide-item a {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 32px;
  background: linear-gradient(to top, rgba(0, 0, 0, .72) 0%, rgba(0, 0, 0, .1) 60%, transparent 100%);
}
.slide-item .s-tag {
  align-self: flex-start;
  margin-bottom: 10px;
  padding: 2px 10px;
  border-radius: 20px;
  background: var(--gold);
  color: #6b4b00;
  font-size: 12px;
  font-weight: 700;
}
.slide-item h3 {
  font-size: 26px;
  color: #fff;
  font-weight: 700;
  text-shadow: 0 2px 8px rgba(0, 0, 0, .4);
}
.slide-item p {
  margin-top: 6px;
  font-size: 14px;
  color: rgba(255, 255, 255, .9);
}
.swiper-pagination {
  position: absolute;
  right: 16px; bottom: 16px;
  display: flex;
  gap: 6px;
  z-index: 5;
}
.swiper-pagination .dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .5);
  cursor: pointer;
  transition: all .3s;
}
.swiper-pagination .dot.active {
  width: 22px;
  border-radius: 4px;
  background: var(--card);
}
.slider-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 36px; height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(0, 0, 0, .3);
  color: #fff;
  font-size: 18px;
  z-index: 5;
  opacity: 0;
  transition: opacity .3s;
}
.slider-left:hover .slider-arrow { opacity: 1; }
.slider-arrow.prev { left: 12px; }
.slider-arrow.next { right: 12px; }

.slider-right {
  display: grid;
  grid-template-rows: 1fr 1fr;
  gap: 14px;
}
.slider-right .item {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--line-strong);
}
.slider-right .item a {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 16px;
  background: linear-gradient(to top, rgba(0, 0, 0, .68), transparent 70%);
}
.slider-right .item b { color: #fff; font-size: 15px; font-weight: 600; }
.slider-right .item span { color: rgba(255, 255, 255, .85); font-size: 12px; }

/* 搜索条 */
.slider-bottom-search { padding: 14px 0; }
.search-form {
  display: flex;
  height: 46px;
  background: var(--card);
  border: 2px solid var(--brand);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.search-form input {
  flex: 1;
  height: 100%;
  padding: 0 16px;
  border: 0;
  font-size: 14px;
  color: var(--ink);
}
.search-form button {
  width: 108px;
  height: 100%;
  background: var(--brand);
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  transition: background .25s;
}
.search-form button:hover { background: var(--brand-dark); }

/* 广告位入口 */
.banner-bottom { padding-bottom: 6px; }
.modown-ad-items {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}
.modown-ad-items .item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  transition: all .28s;
}
.modown-ad-items .item:hover { transform: translateY(-3px); box-shadow: var(--shadow-hover); }
.modown-ad-items .ad-ico {
  width: 42px; height: 42px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  font-size: 20px;
  color: #fff;
}
.modown-ad-items .ad-txt b { display: block; font-size: 14px; color: var(--ink); }
.modown-ad-items .ad-txt span { font-size: 12px; color: var(--muted); }

/* ==========================================================
 * 内容区与工具卡片
 * ========================================================== */
.main { padding: 16px 0 40px; }
.contents { min-height: 300px; }

.mocat { margin-bottom: 34px; }
.mocat > .container > h2 {
  font-size: 20px;
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.mocat > .container > h2::before {
  content: '';
  width: 4px; height: 18px;
  border-radius: 2px;
  background: var(--brand);
}
.mocat .desc { font-size: 13px; color: var(--muted); margin-bottom: 14px; }

/* 分类快捷标签 */
.child {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}
.child li a {
  display: block;
  padding: 5px 14px;
  border-radius: 20px;
  background: var(--card);
  border: 1px solid var(--line);
  font-size: 13px;
  color: var(--text);
  transition: all .22s;
}
.child li a:hover { border-color: var(--brand); color: var(--brand); }
.child li a.active {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
  font-weight: 500;
}

/* 卡片网格 */
.grids {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.post.grid {
  background: var(--card);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform .28s, box-shadow .28s;
}
.post.grid:hover { transform: translateY(-4px); box-shadow: var(--shadow-hover); }
.post.grid .img {
  position: relative;
  padding-top: 56.25%;
  overflow: hidden;
  background: var(--line-strong);
}
.post.grid .img a { position: absolute; inset: 0; }
.post.grid .img img,
.post.grid .img .ph {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .4s;
}
.post.grid:hover .img img,
.post.grid:hover .img .ph { transform: scale(1.06); }
.post.grid .img .corner {
  position: absolute;
  left: 8px; top: 8px;
  z-index: 2;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 600;
  color: #fff;
  background: rgba(0, 0, 0, .55);
  backdrop-filter: blur(4px);
}
/* 占位封面（渐变+图标，纯 CSS 不依赖图片） */
.ph { position: relative; overflow: hidden; }
.ph-inner {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10%;
  text-align: center;
  color: #fff;
}
.ph-inner::before {
  content: '';
  position: absolute;
  right: -18%; top: -30%;
  width: 70%; height: 160%;
  background: rgba(255, 255, 255, .12);
  transform: rotate(18deg);
}
.ph-ico {
  position: relative;
  font-size: 30px;
  line-height: 1;
  text-shadow: 0 2px 6px rgba(0, 0, 0, .25);
}
.ph-title {
  position: relative;
  font-size: 12.5px;
  line-height: 1.4;
  font-weight: 600;
  text-shadow: 0 1px 4px rgba(0, 0, 0, .3);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.post.grid .con { padding: 12px 14px 14px; }
.post.grid .cat {
  margin-bottom: 6px;
  font-size: 12px;
  color: var(--muted);
}
.post.grid .cat a { color: var(--brand-dark); }
.post.grid .cat a:hover { text-decoration: underline; }
.post.grid h3 {
  font-size: 15px;
  font-weight: 600;
  line-height: 1.45;
  margin-bottom: 6px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 43px;
}
.post.grid h3 a { color: var(--ink); }
.post.grid h3 a:hover { color: var(--brand); }
.post.grid .excerpt {
  font-size: 12.5px;
  color: var(--muted);
  line-height: 1.6;
  height: 40px;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
}
.post.grid .grid-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px dashed var(--line);
  font-size: 12px;
  color: var(--muted);
}
.post.grid .grid-meta .views::before { content: '👁 '; }
.post.grid .grid-meta .time::before { content: '🕒 '; }

/* 列表模式（分类页可切换） */
.grid-list { grid-template-columns: 1fr; }
.grid-list .post.grid { display: grid; grid-template-columns: 220px 1fr; }
.grid-list .post.grid .img { padding-top: 0; height: 100%; min-height: 132px; }
.grid-list .post.grid h3 { -webkit-line-clamp: 1; line-clamp: 1; min-height: auto; }
.grid-list .post.grid .excerpt { height: auto; -webkit-line-clamp: 3; line-clamp: 3; }

/* 空状态 */
.empty-state {
  padding: 60px 20px;
  text-align: center;
  color: var(--muted);
  background: var(--card);
  border-radius: var(--radius);
}
.empty-state .ico { font-size: 44px; margin-bottom: 10px; }

/* ==========================================================
 * 会员价格表
 * ========================================================== */
.vip-section { padding: 10px 0 20px; }
.vip-section .sec-title {
  text-align: center;
  margin-bottom: 6px;
  font-size: 24px;
}
.vip-section .sec-desc {
  text-align: center;
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 24px;
}
.vip-plans {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  align-items: start;
}
.vip-plan {
  position: relative;
  background: var(--card);
  border-radius: var(--radius);
  padding: 26px 20px 22px;
  text-align: center;
  box-shadow: var(--shadow);
  border: 2px solid transparent;
  transition: all .28s;
}
.vip-plan:hover { transform: translateY(-4px); box-shadow: var(--shadow-hover); }
.vip-plan.hot { border-color: var(--gold); }
.vip-plan .plan-ribbon {
  position: absolute;
  top: -12px; left: 50%;
  transform: translateX(-50%);
  padding: 2px 14px;
  border-radius: 20px;
  background: linear-gradient(135deg, var(--gold), #ff9500);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}
.vip-plan .p-name { font-size: 16px; color: var(--ink); margin-bottom: 12px; }
.vip-plan .p-price {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 4px;
  color: var(--danger);
  margin-bottom: 4px;
}
.vip-plan .p-price .sym { font-size: 16px; font-weight: 600; }
.vip-plan .p-price .num { font-size: 34px; font-weight: 700; line-height: 1; }
.vip-plan .p-price .unit { font-size: 13px; color: var(--muted); }
.vip-plan .p-origin { font-size: 12px; color: var(--muted); margin-bottom: 14px; min-height: 20px; }
.vip-plan .p-origin del { color: #6b7684; }
.vip-plan .p-perks {
  text-align: left;
  margin: 16px 0 18px;
  padding-top: 16px;
  border-top: 1px dashed var(--line);
}
.vip-plan .p-perks li {
  position: relative;
  padding-left: 20px;
  margin-bottom: 8px;
  font-size: 13px;
  color: var(--text);
  line-height: 1.5;
}
.vip-plan .p-perks li::before {
  content: '✓';
  position: absolute;
  left: 0; top: 0;
  color: var(--brand);
  font-weight: 700;
}
.vip-plan .btn { width: 100%; }

/* ==========================================================
 * 分类列表页
 * ========================================================== */
.page-hero {
  background: linear-gradient(135deg, #10222a, #131a26);
  padding: 26px 0 22px;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--line);
}
.breadcrumb {
  font-size: 12.5px;
  color: var(--muted);
  margin-bottom: 8px;
}
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--brand); }
.breadcrumb .sep { margin: 0 6px; color: #ccc; }
.page-hero h1 {
  font-size: 24px;
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}
.page-hero .hero-desc { font-size: 13px; color: var(--text); }

.cat-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 20px;
  align-items: start;
}
.cat-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  padding: 12px 14px;
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  margin-bottom: 16px;
}
.cat-toolbar .sort-tabs { display: flex; gap: 4px; flex-wrap: wrap; }
.cat-toolbar .sort-tabs a {
  padding: 4px 12px;
  border-radius: 16px;
  font-size: 13px;
  color: var(--text);
}
.cat-toolbar .sort-tabs a:hover { background: var(--bg); }
.cat-toolbar .sort-tabs a.active { background: var(--brand); color: #fff; }
.view-switch { display: flex; gap: 4px; }
.view-switch button {
  width: 30px; height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  color: var(--muted);
  font-size: 15px;
}
.view-switch button.active { background: var(--brand-soft); color: var(--brand); }

/* 侧边栏 */
.sidebar .widget {
  background: var(--card);
  border-radius: var(--radius);
  padding: 16px;
  box-shadow: var(--shadow);
  margin-bottom: 16px;
}
.sidebar .widget h3 {
  font-size: 15px;
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  gap: 6px;
}
.sidebar .widget h3::before {
  content: '';
  width: 3px; height: 14px;
  border-radius: 2px;
  background: var(--brand);
}
.cat-tree li a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  font-size: 13.5px;
  color: var(--text);
}
.cat-tree li a:hover { background: var(--bg); color: var(--brand); }
.cat-tree li a.active { background: var(--brand-soft); color: var(--brand-dark); font-weight: 600; }
.cat-tree li a .cnt { font-size: 12px; color: var(--muted); }
.cat-tree .sub { padding-left: 12px; }
.cat-tree .sub a { font-size: 13px; }

.rank-list li {
  display: flex;
  gap: 10px;
  padding: 9px 0;
  border-bottom: 1px dashed var(--line);
}
.rank-list li:last-child { border-bottom: 0; }
.rank-list .no {
  flex-shrink: 0;
  width: 20px; height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  background: var(--bg);
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}
.rank-list li:nth-child(1) .no { background: #ff5b5b; color: #fff; }
.rank-list li:nth-child(2) .no { background: #ff9500; color: #fff; }
.rank-list li:nth-child(3) .no { background: var(--gold); color: #fff; }
.rank-list .rt {
  font-size: 13px;
  color: var(--ink);
  line-height: 1.45;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.rank-list .rt:hover { color: var(--brand); }
.rank-list .rm { font-size: 11.5px; color: var(--muted); }

.tag-cloud { display: flex; flex-wrap: wrap; gap: 8px; }
.tag-cloud a {
  padding: 4px 12px;
  border-radius: 14px;
  background: var(--bg);
  font-size: 12.5px;
  color: var(--text);
}
.tag-cloud a:hover { background: var(--brand); color: #fff; }

/* 分页 */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 24px;
}
.pagination a, .pagination span {
  min-width: 36px;
  height: 36px;
  padding: 0 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  background: var(--card);
  font-size: 13px;
  color: var(--text);
  box-shadow: var(--shadow);
}
.pagination a:hover { background: var(--brand); color: #fff; }
.pagination .current { background: var(--brand); color: #fff; font-weight: 600; }
.pagination .disabled { color: #4b5563; cursor: not-allowed; }

/* ==========================================================
 * 工具详情页
 * ========================================================== */
.detail-layout {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 20px;
  align-items: start;
}
.detail-main {
  background: var(--card);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow);
}
.detail-head {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 22px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--line);
}
.detail-cover {
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--line-strong);
  aspect-ratio: 16 / 10;
}
.detail-cover .ph { width: 100%; height: 100%; }
.detail-info h1 {
  font-size: 22px;
  line-height: 1.4;
  margin-bottom: 10px;
}
.detail-metas {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}
.detail-metas .m {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: 4px;
  background: var(--bg);
  font-size: 12px;
  color: var(--text);
}
.detail-info .excerpt {
  font-size: 13.5px;
  color: var(--text);
  background: var(--brand-soft);
  border-left: 3px solid var(--brand);
  padding: 10px 14px;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  margin-bottom: 16px;
  line-height: 1.7;
}
.detail-price-box {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  padding: 14px 0;
}
.detail-price-box .now {
  font-size: 30px;
  font-weight: 700;
  color: var(--danger);
  line-height: 1;
}
.detail-price-box .now .sym { font-size: 16px; }
.detail-price-box .now.free { color: #5cb85c; font-size: 22px; }
.detail-price-box .old { font-size: 13px; color: var(--muted); }
.detail-price-box .old del { color: #6b7684; }
.detail-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 4px; }
.detail-stats {
  display: flex;
  gap: 20px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px dashed var(--line);
  font-size: 12.5px;
  color: var(--muted);
}
.detail-stats b { color: var(--ink); font-weight: 600; }

/* 详情正文 */
.detail-body { padding-top: 20px; }
.detail-body h2 {
  font-size: 17px;
  margin: 26px 0 12px;
  padding-left: 10px;
  border-left: 4px solid var(--brand);
}
.detail-body h2:first-child { margin-top: 0; }
.detail-body h3 { font-size: 15px; margin: 18px 0 10px; }
.detail-body p { margin-bottom: 10px; line-height: 1.9; color: var(--text); }
.detail-body ul { margin-bottom: 14px; }
.detail-body ul.features li {
  position: relative;
  padding-left: 22px;
  margin-bottom: 9px;
  line-height: 1.8;
  color: var(--text);
}
.detail-body ul.features li::before {
  content: '✓';
  position: absolute;
  left: 0; top: 1px;
  width: 16px; height: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--brand);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
}
.detail-body ol.steps { counter-reset: step; margin-bottom: 14px; }
.detail-body ol.steps li {
  position: relative;
  padding-left: 32px;
  margin-bottom: 10px;
  line-height: 1.8;
  color: var(--text);
  counter-increment: step;
}
.detail-body ol.steps li::before {
  content: counter(step);
  position: absolute;
  left: 0; top: 3px;
  width: 22px; height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--brand-soft);
  color: var(--brand-dark);
  font-size: 12px;
  font-weight: 700;
}
.changelog { border-left: 2px solid var(--line); padding-left: 16px; margin-bottom: 14px; }
.changelog li {
  position: relative;
  margin-bottom: 10px;
  font-size: 13.5px;
  color: var(--text);
  line-height: 1.7;
}
.changelog li::before {
  content: '';
  position: absolute;
  left: -21px; top: 9px;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--brand);
}
.tips-box {
  background: var(--gold-soft);
  border: 1px solid #ffe9b0;
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  margin: 18px 0;
  font-size: 13px;
  color: #8a6100;
  line-height: 1.8;
}
.tips-box b { color: #6b4b00; }

/* 下载弹窗 */
.download-panel {
  margin-top: 22px;
  padding: 22px;
  border-radius: var(--radius);
  background: linear-gradient(135deg, #10222a, #1a1430);
  border: 1px dashed var(--brand);
  text-align: center;
}
.download-panel h3 { font-size: 17px; margin-bottom: 8px; }
.download-panel p { font-size: 13px; color: var(--muted); margin-bottom: 16px; }
.download-panel .dl-links {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 14px;
}
.download-panel .dl-links a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 18px;
  border-radius: var(--radius-sm);
  background: var(--card);
  font-size: 13px;
  color: var(--ink);
  box-shadow: var(--shadow);
}
.download-panel .dl-links a:hover { color: var(--brand); transform: translateY(-2px); }

/* 相关推荐 */
.related { margin-top: 22px; }
.related .grids { grid-template-columns: repeat(4, 1fr); }

/* 侧边下载卡 */
.side-card {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px;
  margin-bottom: 16px;
}
.side-card h3 {
  font-size: 15px;
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}
.side-card .sc-price {
  text-align: center;
  padding: 6px 0 14px;
}
.side-card .sc-price .num {
  font-size: 32px;
  font-weight: 700;
  color: var(--danger);
  line-height: 1;
}
.side-card .sc-price .num.free { color: #5cb85c; font-size: 24px; }
.side-card .sc-price .sym { font-size: 15px; }
.side-card .sc-price .sub { font-size: 12px; color: var(--muted); margin-top: 4px; }
.side-card .sc-meta {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px dashed var(--line);
  font-size: 13px;
}
.side-card .sc-meta li {
  display: flex;
  justify-content: space-between;
  margin-bottom: 8px;
  color: var(--muted);
}
.side-card .sc-meta li b { color: var(--ink); font-weight: 500; }
.side-card .sc-tip {
  margin-top: 12px;
  font-size: 12px;
  color: var(--muted);
  line-height: 1.7;
}

/* ==========================================================
 * 通用单页 / 搜索页
 * ========================================================== */
.single-page {
  background: var(--card);
  border-radius: var(--radius);
  padding: 30px;
  box-shadow: var(--shadow);
  min-height: 400px;
}
.single-page h1 { font-size: 24px; margin-bottom: 16px; }
.single-page h2 { font-size: 18px; margin: 24px 0 12px; padding-left: 10px; border-left: 4px solid var(--brand); }
.single-page h3 { font-size: 15px; margin: 18px 0 10px; }
.single-page p { margin-bottom: 12px; line-height: 1.9; }
.single-page ul li { position: relative; padding-left: 18px; margin-bottom: 8px; line-height: 1.8; }
.single-page ul li::before {
  content: '';
  position: absolute;
  left: 2px; top: 11px;
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--brand);
}
.single-page table {
  width: 100%;
  border-collapse: collapse;
  margin: 14px 0;
  font-size: 13px;
}
.single-page table th,
.single-page table td {
  border: 1px solid var(--line);
  padding: 9px 12px;
  text-align: left;
}
.single-page table th { background: var(--bg); color: var(--ink); font-weight: 600; }
.single-page .meta-info {
  font-size: 12.5px;
  color: var(--muted);
  padding-bottom: 14px;
  margin-bottom: 18px;
  border-bottom: 1px solid var(--line);
}

.search-bar-page {
  background: var(--card);
  border-radius: var(--radius);
  padding: 16px;
  box-shadow: var(--shadow);
  margin-bottom: 18px;
}
.search-bar-page .search-form { max-width: 640px; }
.result-tip {
  padding: 12px 16px;
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  margin-bottom: 16px;
  font-size: 13.5px;
  color: var(--text);
}
.result-tip b { color: var(--danger); }
.result-tip em { font-style: normal; color: var(--brand); font-weight: 600; }

/* ==========================================================
 * 页脚
 * ========================================================== */
.footer {
  background: #0b0e13;
  color: #999;
  padding: 40px 0 0;
  margin-top: 20px;
}
.footer .f-top {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr;
  gap: 30px;
  padding-bottom: 30px;
  border-bottom: 1px solid #1c222c;
}
.footer h4 {
  color: #fff;
  font-size: 15px;
  margin-bottom: 14px;
  font-weight: 600;
}
.footer .f-brand .slogan { color: #ddd; font-size: 15px; margin-bottom: 6px; }
.footer .f-brand .sub { color: #888; font-size: 13px; margin-bottom: 14px; }
.footer .f-brand .contact {
  font-size: 13px;
  line-height: 1.9;
  color: #888;
}
.footer .f-brand .contact b { color: var(--gold); }
.footer ul li { margin-bottom: 9px; }
.footer ul li a { color: #999; font-size: 13px; }
.footer ul li a:hover { color: var(--brand); }
.footer .f-bottom {
  padding: 18px 0 26px;
  text-align: center;
  font-size: 12.5px;
  color: var(--muted);
  line-height: 1.9;
}
.footer .f-bottom a:hover { color: var(--brand); }

/* 回到顶部 */
.back-top {
  position: fixed;
  right: 20px; bottom: 30px;
  width: 42px; height: 42px;
  display: none;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--card);
  color: var(--text);
  box-shadow: var(--shadow-hover);
  font-size: 18px;
  z-index: 900;
}
.back-top.show { display: flex; }
.back-top:hover { background: var(--brand); color: #fff; }

/* 移动端底部工具栏 */
.mobile-tabbar {
  display: none;
  position: fixed;
  left: 0; right: 0; bottom: 0;
  height: 52px;
  background: var(--card);
  border-top: 1px solid var(--line);
  z-index: 1000;
  box-shadow: 0 -2px 10px rgba(0, 0, 0, .06);
}
.mobile-tabbar a {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1px;
  font-size: 11px;
  color: var(--muted);
}
.mobile-tabbar a.active { color: var(--brand); }
.mobile-tabbar a .ti { font-size: 18px; line-height: 1; }

/* 备案信息（ICP + 公安） */
.f-bottom .beian {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 6px 18px;
}
.f-bottom .beian a { display: inline-flex; align-items: center; gap: 4px; }
.police-ico { width: 15px; height: 15px; display: inline-block; vertical-align: -3px; }

/* ---------- 支付弹层 ---------- */
.pay-mask { position: fixed; inset: 0; z-index: 9999; background: rgba(0,0,0,.68);
  display: flex; align-items: center; justify-content: center; padding: 16px; }
.pay-modal { position: relative; width: 100%; max-width: 360px; background: var(--card);
  border: 1px solid var(--line); border-radius: 14px; padding: 26px 22px 22px;
  box-shadow: var(--shadow-hover); text-align: center; }
.pay-close { position: absolute; right: 8px; top: 6px; width: 30px; height: 30px; border: 0;
  background: transparent; color: var(--muted); font-size: 22px; line-height: 1; cursor: pointer; }
.pay-title { margin: 0 0 10px; font-size: 17px; color: var(--ink); font-weight: 600; }
.pay-amount { font-size: 30px; color: var(--gold); font-weight: 600; margin-bottom: 12px; }
.pay-amount span { font-size: 16px; margin-right: 2px; }
.pay-label { display: block; text-align: left; font-size: 13px; color: var(--muted); margin: 10px 0 6px; }
.pay-input { width: 100%; height: 42px; padding: 0 12px; border: 1px solid var(--line-strong);
  border-radius: 8px; background: var(--bg); color: var(--ink); font-size: 15px; }
.pay-input:focus { outline: none; border-color: var(--brand); }
.pay-tip { margin: 12px 0 14px; font-size: 12.5px; color: var(--muted); line-height: 1.7; }
.pay-qr { width: 190px; height: 190px; margin: 4px auto 6px; display: block;
  background: #fff; border-radius: 10px; padding: 8px; }
.pay-status { margin: 10px 0 14px; font-size: 13px; color: var(--brand); }
.pay-ok { width: 56px; height: 56px; margin: 4px auto 10px; border-radius: 50%;
  background: var(--brand-soft); color: var(--brand); font-size: 30px; line-height: 56px; }
.nav-right .vip-chip { color: var(--gold); }

/* ---------- 会员门禁 ---------- */
.locked-box { border: 1px dashed var(--line-strong); border-radius: 10px; padding: 22px 18px;
  text-align: center; background: var(--bg); }
.locked-box .ico { font-size: 26px; margin-bottom: 8px; }
.locked-box p { color: var(--muted); font-size: 13px; margin-bottom: 14px; }
