/* =========================================================
 * AI 导航频道 · ai.css
 * 单浅色主题（综合导航站样式）
 * ========================================================= */

:root {
  --wrap: 1200px;
  --r: 14px;
  --r-sm: 10px;
  --ease: cubic-bezier(.22, .61, .36, 1);

  /* 浅色 */
  --bg: #f4f6fb;
  --bg-hero: #eef2ff;
  --panel: #ffffff;
  --panel-2: #f8fafc;
  --text: #12151c;
  --text-2: #545e70;
  --text-3: #8d97a8;
  --line: #e7ebf3;
  --line-2: #eef1f7;
  --brand: #5563ff;
  --brand-2: #22c1dc;
  --brand-ink: #3d49e0;
  --brand-soft: rgba(85, 99, 255, .09);
  --brand-line: rgba(85, 99, 255, .22);
  --shadow: 0 1px 2px rgba(16, 24, 40, .04), 0 10px 26px -16px rgba(16, 24, 40, .22);
  --shadow-h: 0 18px 36px -18px rgba(85, 99, 255, .45), 0 0 0 1px var(--brand-line);
  --grad: linear-gradient(120deg, #5563ff 0%, #7c6cff 45%, #22c1dc 100%);
  --grad-soft: linear-gradient(120deg, rgba(85, 99, 255, .10), rgba(34, 193, 220, .10));
  --header: rgba(255, 255, 255, .82);
  --chip: #f1f4fa;
  --ico-bg: #fff;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body.ai-body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  -webkit-font-smoothing: antialiased;
  font-size: 14px;
  line-height: 1.55;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a { color: inherit; text-decoration: none; }
::selection { background: rgba(85, 99, 255, .25); }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }

/* ================= 顶部站点入口（嵌在品牌栏内） ================= */
.site-menu {
  display: flex; align-items: center; gap: 6px;
  flex: 1 1 auto; min-width: 0; overflow-x: auto;
  scrollbar-width: none;
}
.site-menu::-webkit-scrollbar { display: none; }
.sitebar-l {
  display: inline-flex; align-items: center;
  padding: 4px 11px; border-radius: 999px;
  font-size: 12.5px; font-weight: 700; color: var(--text-2);
  white-space: nowrap; transition: color .16s, background .16s, box-shadow .16s;
}
.sitebar-l:hover { color: var(--brand-ink); background: var(--brand-soft); }
.sitebar-l.on { color: #fff; background: var(--grad); box-shadow: 0 4px 12px -6px rgba(85, 99, 255, .9); }

/* ================= 顶部 ================= */
.top {
  position: sticky; top: 0; z-index: 80;
  background: var(--header);
  backdrop-filter: blur(16px) saturate(1.6);
  -webkit-backdrop-filter: blur(16px) saturate(1.6);
  border-bottom: 1px solid var(--line);
}
.top-in { display: flex; align-items: center; justify-content: space-between; gap: 18px; height: 66px; }

.logo { display: flex; align-items: center; gap: 10px; flex: 0 0 auto; }
.logo-badge {
  width: 36px; height: 36px; border-radius: 11px;
  display: grid; place-items: center;
  background: var(--grad); color: #fff;
  font-weight: 900; font-size: 15px; letter-spacing: .5px;
  box-shadow: 0 6px 16px -6px rgba(85, 99, 255, .8);
}
.logo-txt { display: flex; flex-direction: column; line-height: 1.15; font-weight: 800; font-size: 16px; letter-spacing: .2px; }
.logo-txt i { font-style: normal; font-weight: 500; font-size: 10px; color: var(--text-3); letter-spacing: 1.2px; text-transform: uppercase; margin-top: 1px; }

.top-nav { display: flex; align-items: center; gap: 2px; flex: 1 1 auto; min-width: 0; }
.nav-l {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 8px 13px; border-radius: 9px;
  font-size: 14px; font-weight: 600; color: var(--text-2);
  white-space: nowrap; cursor: pointer;
  border: 1px solid transparent; background: none; font-family: inherit;
  transition: color .16s, background .16s;
}
.nav-l:hover { color: var(--text); background: var(--chip); }
.nav-l.on { color: var(--brand-ink); background: var(--brand-soft); }
.chev { width: 13px; height: 13px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; opacity: .6; }

.nav-grp { position: relative; }
.nav-grp.open > .nav-grp-btn { color: var(--brand-ink); background: var(--brand-soft); }
.mega {
  position: absolute; top: calc(100% + 6px); left: -8px;
  min-width: 560px; max-width: min(760px, calc(100vw - 40px));
  background: var(--panel); border: 1px solid var(--line);
  border-radius: 16px; box-shadow: 0 24px 60px -24px rgba(16, 24, 40, .35), 0 0 0 1px rgba(0, 0, 0, .02);
  padding: 10px; z-index: 90;
  opacity: 0; visibility: hidden; transform: translateY(-6px);
  transition: opacity .16s var(--ease), transform .16s var(--ease), visibility .16s;
}
.nav-grp.open .mega, .nav-grp:hover .mega { opacity: 1; visibility: visible; transform: translateY(0); }
.mega-in { display: grid; grid-template-columns: repeat(2, minmax(220px, 1fr)); gap: 2px; }
.mega-item {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 10px; border-radius: 11px;
  transition: background .14s;
}
.mega-item:hover { background: var(--brand-soft); }
.mega-ico { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; background: var(--chip); font-size: 15px; flex: 0 0 auto; }
.mega-txt { display: flex; flex-direction: column; min-width: 0; }
.mega-txt b { font-size: 13.5px; font-weight: 700; }
.mega-txt i { font-style: normal; font-size: 11.5px; color: var(--text-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mega-num { margin-left: auto; font-size: 11px; color: var(--text-3); background: var(--chip); border-radius: 999px; padding: 2px 8px; }

.top-right { display: flex; align-items: center; gap: 8px; flex: 0 0 auto; }
.top-search-btn {
  width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center;
  border: 1px solid var(--line); color: var(--text-2); background: var(--panel);
  transition: color .16s, border-color .16s;
}
.top-search-btn:hover { color: var(--brand); border-color: var(--brand-line); }
.top-search-btn svg, .burger svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }

.theme-btn {
  display: inline-flex; align-items: center; gap: 6px;
  height: 36px; padding: 0 12px; border-radius: 10px;
  border: 1px solid var(--line); background: var(--panel); color: var(--text-2);
  font-size: 13px; font-weight: 600; font-family: inherit; cursor: pointer;
  white-space: nowrap;
  transition: color .16s, border-color .16s, background .16s;
}
.theme-btn:hover { color: var(--brand); border-color: var(--brand-line); }
.t-ico { display: inline-flex; line-height: 0; }
.t-ico svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

.burger { display: none; width: 36px; height: 36px; border-radius: 10px; border: 1px solid var(--line); background: var(--panel); color: var(--text-2); cursor: pointer; place-items: center; }

/* ================= Hero ================= */
.hero {
  position: relative; z-index: 20;
  padding: 54px 0 40px;
  background:
    radial-gradient(700px 320px at 18% -10%, rgba(85, 99, 255, .16), transparent 60%),
    radial-gradient(600px 300px at 82% -20%, rgba(34, 193, 220, .14), transparent 60%),
    linear-gradient(180deg, var(--bg-hero), var(--bg));
  border-bottom: 1px solid var(--line);
  text-align: center;
}

.hero-sm { padding: 34px 0 26px; }

.hero-h1 { margin: 0 0 10px; font-size: clamp(28px, 4.2vw, 44px); font-weight: 900; letter-spacing: -.5px; line-height: 1.18; }
.hero-h1 em {
  font-style: normal;
  background: var(--grad);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero-sub {
  margin: 0 auto 26px; max-width: 660px; color: var(--text-2); font-size: 14.5px;
  white-space: normal; overflow-wrap: anywhere; line-height: 1.7;
}
.hero-sub b { color: var(--text); font-weight: 800; }
.hero-sm .hero-sub { margin-bottom: 18px; }

/* 搜索框 */
.search {
  position: relative;
  display: flex; align-items: center; gap: 10px;
  max-width: 620px; margin: 0 auto;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 8px 8px 8px 16px;
  box-shadow: 0 10px 30px -18px rgba(16, 24, 40, .35), 0 1px 2px rgba(16, 24, 40, .04);
  transition: border-color .18s, box-shadow .18s;
}
.search:focus-within { border-color: var(--brand-line); box-shadow: 0 0 0 4px var(--brand-soft), 0 12px 34px -20px rgba(85, 99, 255, .5); }
.s-ico { width: 18px; height: 18px; fill: none; stroke: var(--text-3); stroke-width: 2; stroke-linecap: round; flex: 0 0 auto; }
.search input {
  flex: 1 1 auto; min-width: 0;
  border: 0; outline: 0; background: none;
  color: var(--text); font-size: 15px; font-family: inherit; padding: 8px 0;
}
.search input::placeholder { color: var(--text-3); }
.s-btn {
  flex: 0 0 auto; border: 0; cursor: pointer;
  height: 40px; padding: 0 22px; border-radius: 10px;
  background: var(--grad); color: #fff; font-weight: 700; font-size: 14px; font-family: inherit;
  box-shadow: 0 8px 20px -10px rgba(85, 99, 255, .9);
  transition: filter .16s, transform .16s;
}
.s-btn:hover { filter: brightness(1.06); transform: translateY(-1px); }

/* 搜索下拉 */
.drop {
  position: absolute; top: calc(100% + 10px); left: 0; right: 0;
  background: var(--panel); border: 1px solid var(--line);
  border-radius: 14px; padding: 6px;
  box-shadow: 0 26px 60px -26px rgba(16, 24, 40, .45);
  max-height: 400px; overflow-y: auto;
  z-index: 95; text-align: left;
}
.drop[hidden] { display: none; }
.drop-item { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 10px; }
.drop-item:hover { background: var(--brand-soft); }
.drop-ico {
  position: relative; width: 30px; height: 30px; border-radius: 9px; flex: 0 0 auto;
  display: grid; place-items: center; overflow: hidden;
  background-color: hsl(var(--h), 82%, 60%);
  background-image: linear-gradient(135deg, hsl(var(--h), 82%, 62%), hsl(calc(var(--h) + 42), 82%, 54%));
  color: #fff; font-weight: 800; font-size: 13px;
}
.drop-ico img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; background: var(--ico-bg); padding: 5px; opacity: 0; transition: opacity .15s; }
.drop-ico img.ok { opacity: 1; }
.drop-txt { display: flex; flex-direction: column; min-width: 0; }
.drop-txt b { font-size: 13.5px; font-weight: 700; }
.drop-txt i { font-style: normal; font-size: 11.5px; color: var(--text-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.drop-none { padding: 16px; text-align: center; color: var(--text-3); font-size: 13px; }

/* 热门关键词 */
.hotkeys { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 8px; margin-top: 18px; font-size: 13px; }
.hotkeys span { color: var(--text-3); }
.hotkeys a {
  padding: 4px 12px; border-radius: 999px;
  background: var(--panel); border: 1px solid var(--line); color: var(--text-2);
  transition: color .16s, border-color .16s, background .16s;
}
.hotkeys a:hover { color: var(--brand); border-color: var(--brand-line); background: var(--brand-soft); }

/* ================= 分类快捷条 ================= */
.catbar { background: var(--bg); border-bottom: 1px solid var(--line); position: relative; z-index: 10; }
.catbar::after {
  content: ""; position: absolute; right: 0; top: 0; bottom: 1px; width: 44px;
  background: linear-gradient(90deg, transparent, var(--bg) 82%);
  pointer-events: none;
}
.catbar-in {
  display: flex; align-items: center; gap: 6px;
  padding: 10px 20px; overflow-x: auto;
  scrollbar-width: none;
}
.catbar-in::-webkit-scrollbar { display: none; }
.cat-pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 12px; border-radius: 999px;
  font-size: 13px; font-weight: 600; color: var(--text-2);
  background: var(--panel); border: 1px solid var(--line);
  white-space: nowrap; transition: all .16s;
}
.cat-pill span { font-size: 13px; }
.cat-pill i { font-style: normal; font-size: 11px; color: var(--text-3); background: var(--chip); border-radius: 999px; padding: 1px 6px; }
.cat-pill:hover { color: var(--brand-ink); border-color: var(--brand-line); background: var(--brand-soft); }
.cat-pill.on { color: #fff; background: var(--grad); border-color: transparent; box-shadow: 0 6px 16px -8px rgba(85, 99, 255, .9); }
.cat-pill.on i { color: rgba(255, 255, 255, .85); background: rgba(255, 255, 255, .2); }

/* ================= 主体 ================= */
.main { flex: 1 0 auto; padding: 26px 20px 60px; }

.sec { margin-bottom: 34px; }
.sec-head { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; flex-wrap: wrap; }
.sec-t { margin: 0; font-size: 18px; font-weight: 800; letter-spacing: -.2px; display: inline-flex; align-items: center; gap: 8px; }
.sec-flame { font-size: 17px; }
.sec-ico { font-size: 17px; }
.sec-n { font-size: 12.5px; color: var(--text-3); }
.sec-more { margin-left: auto; font-size: 12.5px; font-weight: 600; color: var(--brand); padding: 2px 4px; }
.sec-more:hover { text-decoration: underline; }

/* 网格 */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(255px, 1fr)); gap: 12px; }
.grid-hot { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.grid-mini { grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px; }

/* 工具卡片 */
.tool {
  display: flex; align-items: flex-start; gap: 11px;
  padding: 13px 14px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--r);
  box-shadow: var(--shadow);
  transition: transform .18s var(--ease), box-shadow .18s var(--ease), border-color .18s;
  position: relative; overflow: hidden;
}
.tool::after {
  content: ""; position: absolute; inset: 0;
  background: var(--grad-soft); opacity: 0; transition: opacity .2s; pointer-events: none;
}
.tool:hover { transform: translateY(-3px); box-shadow: var(--shadow-h); border-color: transparent; }
.tool:hover::after { opacity: .55; }
.tool-hot { padding: 15px; }

.ico {
  position: relative; flex: 0 0 auto;
  width: 42px; height: 42px; border-radius: 12px;
  display: grid; place-items: center; overflow: hidden;
  /* 逗号语法 + 纯色兜底：兼容不支持 CSS Color 4 空格语法的旧内核 */
  background-color: hsl(var(--h), 82%, 60%);
  background-image: linear-gradient(135deg, hsl(var(--h), 84%, 63%), hsl(calc(var(--h) + 42), 84%, 55%));
  color: #fff; font-weight: 800; font-size: 16px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .25);
  z-index: 1;
}
.ico-sm { width: 34px; height: 34px; border-radius: 10px; font-size: 13.5px; }
.ico b { font-weight: 800; line-height: 1; }
.ico img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: contain; background: var(--ico-bg); padding: 7px;
  z-index: 2;
  opacity: 0; transition: opacity .18s ease;
}
.ico img.ok { opacity: 1; }
.ico-sm img { padding: 5px; }

.t-body { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 2px; z-index: 1; }
.t-name {
  display: flex; align-items: center; gap: 6px;
  font-size: 14.5px; font-weight: 800; color: var(--text);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.t-badge {
  font-style: normal; font-size: 9px; font-weight: 800; letter-spacing: .4px;
  padding: 1px 5px; border-radius: 4px; color: #fff;
  background: linear-gradient(120deg, #ff6b6b, #ff9f43);
  flex: 0 0 auto;
}
.t-desc {
  font-size: 12.5px; color: var(--text-2); line-height: 1.45;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.t-tags { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 5px; }
.t-tags i {
  font-style: normal; font-size: 10.5px; font-weight: 600;
  color: var(--text-3); background: var(--chip);
  padding: 1px 7px; border-radius: 5px;
}

/* 小卡 */
.mini {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px; background: var(--panel);
  border: 1px solid var(--line); border-radius: var(--r-sm);
  box-shadow: var(--shadow); transition: transform .16s var(--ease), box-shadow .16s;
}
.mini:hover { transform: translateY(-2px); box-shadow: var(--shadow-h); }
.mini-body { display: flex; flex-direction: column; min-width: 0; }
.mini .t-name { font-size: 13.5px; }
.mini .t-desc { font-size: 11.5px; -webkit-line-clamp: 1; }

/* ================= 首页：左侧分类栏 + tab + 搜索切换 ================= */
.home-layout { display: flex; gap: 22px; align-items: flex-start; }
.home-main { flex: 1 1 auto; min-width: 0; }

.rail {
  flex: 0 0 196px; width: 196px;
  position: sticky; top: 82px;
  max-height: calc(100vh - 104px); overflow-y: auto;
  padding: 8px; border-radius: var(--r);
  background: var(--panel); border: 1px solid var(--line);
  box-shadow: var(--shadow);
  scrollbar-width: thin;
}
.rail-t { font-size: 11px; font-weight: 800; letter-spacing: .08em; color: var(--text-3); padding: 6px 8px 8px; }
.rail-grp { font-size: 11px; font-weight: 700; color: var(--text-3); padding: 10px 8px 4px; }
.rail-item {
  display: flex; align-items: center; gap: 8px;
  padding: 7px 9px; border-radius: 9px;
  font-size: 13px; font-weight: 600; color: var(--text-2);
  transition: background .14s, color .14s;
}
.rail-item:hover { background: var(--chip); color: var(--text); }
.rail-item.on { background: var(--brand-soft); color: var(--brand-ink); }
.rail-ico { width: 18px; text-align: center; font-size: 13px; flex: 0 0 auto; }
.rail-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rail-item i { margin-left: auto; font-style: normal; font-size: 10.5px; color: var(--text-3); background: var(--chip); border-radius: 999px; padding: 1px 6px; }

/* tab 切换 */
.tabs { display: inline-flex; gap: 4px; background: var(--chip); padding: 3px; border-radius: 10px; }
.tab {
  border: 0; background: none; cursor: pointer; font-family: inherit;
  padding: 6px 14px; border-radius: 8px;
  font-size: 13.5px; font-weight: 700; color: var(--text-2);
  transition: background .16s, color .16s;
}
.tab:hover { color: var(--text); }
.tab.on { background: var(--panel); color: var(--brand-ink); box-shadow: 0 1px 3px rgba(16,24,40,.12); }
.tab-panel { display: none; }
.tab-panel.on { display: block; }

/* 搜索来源切换 */
.engines { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 6px; margin-top: 14px; }
.eng-label { font-size: 12.5px; color: var(--text-3); }
.eng {
  border: 1px solid var(--line); background: var(--panel); color: var(--text-2);
  font-family: inherit; font-size: 12.5px; font-weight: 600;
  padding: 4px 11px; border-radius: 999px; cursor: pointer;
  transition: color .16s, border-color .16s, background .16s;
}
.eng:hover { color: var(--brand); border-color: var(--brand-line); }
.eng.on { color: #fff; background: var(--grad); border-color: transparent; }

/* 更紧凑的工具卡网格（对齐 ai-bot 一屏 4~5 列） */
.grid-dense { grid-template-columns: repeat(auto-fill, minmax(212px, 1fr)); gap: 10px; }
.grid-dense .tool { padding: 11px 12px; }
.grid-dense .ico { width: 38px; height: 38px; border-radius: 11px; font-size: 14px; }
.grid-dense .ico img { padding: 6px; }
.grid-dense .t-name { font-size: 13.5px; }
.grid-dense .t-desc { font-size: 12px; -webkit-line-clamp: 1; }
.grid-dense .t-tags { display: none; }

@media (min-width: 1181px) {
  /* 桌面端有左侧分类栏，顶部快捷条就多余了 */
  .ai-theme-home .catbar { display: none; }
}
@media (max-width: 1180px) {
  .rail { display: none; }
}

/* ================= 分类页布局 ================= */
.layout { display: flex; gap: 22px; align-items: flex-start; }
.side {
  flex: 0 0 208px; width: 208px;
  position: sticky; top: 86px;
  max-height: calc(100vh - 110px); overflow-y: auto;
  background: var(--panel); border: 1px solid var(--line);
  border-radius: var(--r); padding: 10px;
  box-shadow: var(--shadow);
  scrollbar-width: thin;
}
.side-t { font-size: 11px; font-weight: 800; letter-spacing: .08em; color: var(--text-3); text-transform: uppercase; padding: 4px 8px 8px; }
.side-grp { font-size: 11px; font-weight: 700; color: var(--text-3); padding: 10px 8px 4px; }
.side-item {
  display: flex; align-items: center; gap: 8px;
  padding: 7px 9px; border-radius: 9px;
  font-size: 13px; font-weight: 600; color: var(--text-2);
  transition: background .14s, color .14s;
}
.side-item:hover { background: var(--chip); color: var(--text); }
.side-item.on { background: var(--brand-soft); color: var(--brand-ink); }
.side-ico { font-size: 14px; width: 20px; text-align: center; flex: 0 0 auto; }
.side-item i { margin-left: auto; font-style: normal; font-size: 10.5px; color: var(--text-3); background: var(--chip); border-radius: 999px; padding: 1px 6px; }
.content { flex: 1 1 auto; min-width: 0; }

/* ================= 空状态 ================= */
.empty-inline { grid-column: 1 / -1; padding: 26px 0; text-align: center; color: var(--text-3); font-size: 13px; border: 1px dashed var(--line); border-radius: var(--r); }
.empty { text-align: center; padding: 70px 20px; color: var(--text-2); }
.empty-ico { font-size: 46px; margin-bottom: 12px; }
.empty p { margin: 0 0 18px; font-size: 14px; }
.empty-btn {
  display: inline-flex; padding: 9px 20px; border-radius: 10px;
  background: var(--grad); color: #fff; font-weight: 700; font-size: 13.5px;
  box-shadow: 0 8px 20px -10px rgba(85, 99, 255, .9);
}

/* ================= 页脚 ================= */
.foot { border-top: 1px solid var(--line); background: var(--panel); padding: 26px 0 30px; text-align: center; }
.foot p { margin: 5px 0; font-size: 12.5px; color: var(--text-3); }
.foot-t { color: var(--text) !important; font-weight: 700; font-size: 13.5px !important; }
.foot-l { display: flex; justify-content: center; gap: 16px; }
.foot-l a { color: var(--text-2); font-weight: 600; }
.foot-l a:hover { color: var(--brand); }
.foot-c a { color: var(--text-3); }
.foot-c span { display: block; margin-top: 2px; }

/* 回到顶部 */
.to-top {
  position: fixed; right: 22px; bottom: 26px; z-index: 70;
  width: 42px; height: 42px; border-radius: 12px;
  display: grid; place-items: center; cursor: pointer;
  border: 1px solid var(--line); background: var(--panel); color: var(--text-2);
  box-shadow: var(--shadow);
  opacity: 0; visibility: hidden; transform: translateY(8px);
  transition: all .2s var(--ease);
}
.to-top.show { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { color: var(--brand); border-color: var(--brand-line); }
.to-top svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }

/* ================= 响应式 ================= */
@media (max-width: 1080px) {
  .mega { min-width: 460px; }
  .mega-in { grid-template-columns: 1fr; }
}

@media (max-width: 980px) {
  .burger { display: grid; }
  .top-nav {
    position: absolute; left: 0; right: 0; top: 66px;
    flex-direction: column; align-items: stretch; gap: 2px;
    background: var(--panel); border-bottom: 1px solid var(--line);
    padding: 10px 16px 16px; display: none;
    box-shadow: 0 20px 40px -24px rgba(16, 24, 40, .3);
    max-height: calc(100vh - 66px); overflow-y: auto;
  }
  body.nav-open .top-nav { display: flex; }
  .nav-l { padding: 11px 12px; font-size: 14.5px; }
  .nav-grp { position: static; }
  .mega {
    position: static; min-width: 0; max-width: none; left: 0;
    opacity: 1; visibility: visible; transform: none; display: none;
    box-shadow: none; border: 1px solid var(--line); margin: 4px 0 6px;
    max-height: none;
  }
  .nav-grp.open .mega { display: block; }
  .nav-grp:hover .mega { display: none; }
  .nav-grp.open:hover .mega { display: block; }
  .mega-in { grid-template-columns: 1fr; }
  .layout { flex-direction: column; }
  .side {
    position: static; width: 100%; flex: none; max-height: none;
    display: flex; flex-wrap: wrap; gap: 4px; padding: 8px;
  }
  .side-t, .side-grp { display: none; }
  .side-item { padding: 6px 10px; font-size: 12.5px; }
  .side-ico { width: 16px; }
}

@media (max-width: 640px) {
  .wrap { padding: 0 14px; }
  .main { padding: 20px 14px 44px; }
  .side { display: none; } /* 手机端顶部已有分类快捷条，侧栏不再重复占屏 */
  .top-in { height: 60px; gap: 10px; }
  .top-nav { top: 60px; }
  .logo-txt i { display: none; }
  .hero { padding: 34px 0 26px; }
  .hero-sub { font-size: 13px; margin-bottom: 20px; }
  .search { padding: 6px 6px 6px 13px; border-radius: 12px; }
  .search input { font-size: 14px; }
  .s-btn { height: 36px; padding: 0 15px; font-size: 13px; }
  .grid, .grid-hot, .grid-mini { grid-template-columns: 1fr; }
  .theme-btn .t-txt { display: none; }
  .theme-btn { width: 36px; padding: 0; justify-content: center; }
  .sec-t { font-size: 16.5px; }
  .sec-more { margin-left: 0; }
  .to-top { right: 14px; bottom: 18px; }
}
