/* ============================================================
   TechStack Hub - 深色科技风视觉体系
   ============================================================ */
:root {
  --bg: #0a0e1a;
  --bg-soft: #0f1526;
  --card: #121a2b;
  --card-hover: #16223a;
  --border: rgba(148, 163, 184, 0.12);
  --border-strong: rgba(148, 163, 184, 0.22);
  --text: #e6edf7;
  --text-muted: #8b98b3;
  --accent-1: #22d3ee;
  --accent-2: #6366f1;
  --accent-3: #a855f7;
  --gradient: linear-gradient(120deg, #22d3ee 0%, #6366f1 55%, #a855f7 100%);
  --danger: #f87171;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow-card: 0 8px 30px rgba(2, 6, 23, 0.45);
  --font: "Segoe UI", "PingFang SC", "Microsoft YaHei", "Noto Sans SC", system-ui, -apple-system, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

/* 全局渐变/辉光背景 */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background:
    radial-gradient(600px 360px at 18% -4%, rgba(99, 102, 241, 0.16), transparent 60%),
    radial-gradient(520px 320px at 88% 6%, rgba(34, 211, 238, 0.12), transparent 60%),
    radial-gradient(700px 420px at 60% 110%, rgba(168, 85, 247, 0.10), transparent 60%);
  pointer-events: none;
  z-index: 0;
}

::selection { background: rgba(99, 102, 241, 0.5); color: #fff; }

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button { font-family: inherit; cursor: pointer; }

/* ==================== 顶部导航 ==================== */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 14px clamp(20px, 5vw, 64px);
  background: rgba(10, 14, 26, 0.72);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}
.nav-brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 18px; letter-spacing: 0.3px; }
.nav-brand .logo-mark {
  width: 34px; height: 34px; border-radius: 10px; background: var(--gradient);
  display: grid; place-items: center; font-size: 17px; color: #fff;
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.4);
}
.nav-brand .logo-text b { background: var(--gradient); -webkit-background-clip: text; background-clip: text; color: transparent; }
.nav-links { display: flex; align-items: center; gap: 6px; }
.nav-link {
  padding: 8px 14px; border-radius: 999px; font-size: 14px; color: var(--text-muted);
  transition: all 0.2s; border: 1px solid transparent;
}
.nav-link:hover { color: var(--text); background: rgba(148, 163, 184, 0.08); }
.nav-link.active { color: #fff; background: linear-gradient(120deg, rgba(34, 211, 238, 0.16), rgba(99, 102, 241, 0.18)); border-color: rgba(99, 102, 241, 0.35); }

/* 导航栏内联搜索（列表视图常驻） */
.nav-search { position: relative; flex: 0 1 280px; }
.nav-search input {
  width: 100%; padding: 9px 38px 9px 16px; border-radius: 999px;
  background: rgba(148, 163, 184, 0.08); border: 1px solid var(--border); color: var(--text);
  font-size: 14px; outline: none; transition: border-color 0.2s;
}
.nav-search input:focus { border-color: var(--accent-1); background: rgba(148, 163, 184, 0.12); }
.nav-search input::placeholder { color: var(--text-muted); }
.nav-search .search-ico { position: absolute; right: 14px; top: 50%; transform: translateY(-50%); color: var(--text-muted); font-size: 15px; }

/* ==================== 主体容器 ==================== */
.container { position: relative; z-index: 1; max-width: 1280px; margin: 0 auto; padding: 0 clamp(20px, 5vw, 64px); }

/* ==================== 首页 · Hero ==================== */
.hero { padding: clamp(56px, 9vw, 110px) 0 48px; text-align: center; }
.hero .eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 16px; border-radius: 999px; font-size: 13px;
  border: 1px solid rgba(34, 211, 238, 0.3); color: var(--accent-1);
  background: rgba(34, 211, 238, 0.08); letter-spacing: 1px; margin-bottom: 22px;
}
.hero h1 { font-size: clamp(34px, 6vw, 60px); font-weight: 800; line-height: 1.15; letter-spacing: -0.5px; }
.hero h1 .grad { background: var(--gradient); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero .sub { margin: 18px auto 0; max-width: 640px; color: var(--text-muted); font-size: clamp(15px, 2vw, 17px); }
.hero .sub b { color: var(--text); font-weight: 600; }

/* 大搜索框 */
.hero-search { margin: 38px auto 0; max-width: 660px; }
.hero-search .search-wrap {
  display: flex; align-items: center; gap: 6px; padding: 8px 8px 8px 20px;
  border-radius: 999px; background: var(--card); border: 1px solid var(--border-strong);
  box-shadow: 0 14px 40px rgba(2, 6, 23, 0.5); transition: border-color 0.2s, box-shadow 0.2s;
}
.hero-search .search-wrap:focus-within { border-color: var(--accent-1); box-shadow: 0 0 0 4px rgba(34, 211, 238, 0.12), 0 14px 40px rgba(2, 6, 23, 0.5); }
.hero-search .search-wrap .search-ico { color: var(--accent-1); font-size: 18px; flex-shrink: 0; }
.hero-search input { flex: 1; background: none; border: none; outline: none; color: var(--text); font-size: 16px; padding: 8px 0; }
.hero-search input::placeholder { color: var(--text-muted); }
.hero-search .btn-go {
  padding: 10px 26px; border: none; border-radius: 999px; background: var(--gradient); color: #fff;
  font-size: 15px; font-weight: 600; transition: transform 0.15s, filter 0.2s;
}
.hero-search .btn-go:hover { filter: brightness(1.1); transform: translateY(-1px); }

/* 热门标签 */
.hot-tags { margin-top: 20px; display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; align-items: center; }
.hot-tags .label { color: var(--text-muted); font-size: 13px; }
.hot-tags .tag {
  padding: 5px 13px; border-radius: 999px; font-size: 13px; color: var(--text);
  background: rgba(148, 163, 184, 0.08); border: 1px solid var(--border); transition: all 0.2s; cursor: pointer;
}
.hot-tags .tag:hover { border-color: var(--accent-2); color: #fff; background: rgba(99, 102, 241, 0.15); }

/* 数据统计条 */
.stats-bar {
  display: flex; justify-content: center; gap: clamp(24px, 6vw, 72px);
  margin-top: 52px; padding: 24px 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border);
}
.stat-item { text-align: center; }
.stat-item .num { font-size: clamp(26px, 3vw, 38px); font-weight: 800; background: var(--gradient); -webkit-background-clip: text; background-clip: text; color: transparent; }
.stat-item .cap { margin-top: 2px; font-size: 13px; color: var(--text-muted); }

/* ==================== 首页 · 分类入口 ==================== */
.section { padding: clamp(44px, 6vw, 72px) 0; }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; margin-bottom: 26px; }
.section-head h2 { font-size: clamp(22px, 3vw, 30px); font-weight: 700; }
.section-head h2 .bar { display: inline-block; width: 5px; height: 24px; border-radius: 3px; background: var(--gradient); vertical-align: -3px; margin-right: 12px; }
.section-head p { color: var(--text-muted); font-size: 14px; }

.category-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 16px; }
.category-card {
  display: flex; align-items: center; gap: 14px; padding: 18px;
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s; cursor: pointer;
}
.category-card:hover { transform: translateY(-4px); border-color: rgba(99, 102, 241, 0.5); box-shadow: var(--shadow-card); }
.category-card .ico {
  width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center;
  font-size: 22px; background: rgba(99, 102, 241, 0.14); color: #a5b4fc; flex-shrink: 0;
}
.category-card .ico .iconfont {
  font-size: 24px; line-height: 1; color: #a5b4fc;
  background: var(--gradient); -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.category-card .name { font-weight: 600; font-size: 15px; }
.category-card .cnt { font-size: 12px; color: var(--text-muted); margin-top: 2px; }

/* ==================== 首页 · 精选卡片 ==================== */
.featured-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 18px; }

/* ==================== 技术栈卡片（通用） ==================== */
.stack-card {
  position: relative; display: flex; flex-direction: column; gap: 14px; padding: 20px;
  background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
  transition: transform 0.22s, border-color 0.22s, box-shadow 0.22s; overflow: hidden;
}
.stack-card::before {
  content: ""; position: absolute; inset: 0 0 auto 0; height: 3px; opacity: 0;
  background: var(--gradient); transition: opacity 0.22s;
}
.stack-card:hover { transform: translateY(-5px); border-color: var(--border-strong); box-shadow: var(--shadow-card); }
.stack-card:hover::before { opacity: 1; }

.stack-card .card-top { display: flex; align-items: center; gap: 14px; }
.stack-logo {
  width: 52px; height: 52px; border-radius: 13px; display: grid; place-items: center;
  background: rgba(148, 163, 184, 0.09); border: 1px solid var(--border); flex-shrink: 0;
  overflow: hidden;
}
.stack-logo img { width: 30px; height: 30px; object-fit: contain; }
.stack-logo .fb { width: 100%; height: 100%; display: grid; place-items: center; font-size: 24px; font-weight: 800; color: #fff; }

/* 分类徽章（卡片四角） */
.badge {
  display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: 11.5px; font-weight: 600; letter-spacing: 0.3px;
}
.badge-cat { background: rgba(99, 102, 241, 0.16); color: #a5b4fc; border: 1px solid rgba(99, 102, 241, 0.3); }
.badge-featured { position: absolute; top: 20px; right: -34px; transform: rotate(45deg); background: var(--gradient); color: #fff; font-size: 10px; padding: 3px 42px; letter-spacing: 1px; }

.card-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.stack-card h3 { font-size: 17px; font-weight: 700; }
.stack-card .meta { display: flex; align-items: center; gap: 6px; margin-top: 3px; }
.cat-chip { font-size: 12px; color: var(--text-muted); display: flex; align-items: center; gap: 5px; }
.cat-chip::before { content: ""; width: 6px; height: 6px; border-radius: 50%; display: inline-block; }

.stack-card .desc { font-size: 13.5px; color: var(--text-muted); line-height: 1.65; flex: 1; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.tags-row { display: flex; flex-wrap: wrap; gap: 6px; }
.mini-tag { padding: 2px 9px; border-radius: 6px; font-size: 11px; color: var(--text-muted); background: rgba(148, 163, 184, 0.07); }
.card-link {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 9px 14px; border-radius: var(--radius-sm);
  background: rgba(34, 211, 238, 0.08); border: 1px solid rgba(34, 211, 238, 0.22);
  font-size: 13px; color: var(--accent-1); font-weight: 600; transition: all 0.2s;
}
.card-link:hover { background: var(--gradient); color: #fff; border-color: transparent; }
.card-link .go { font-size: 14px; transition: transform 0.2s; }
.card-link:hover .go { transform: translateX(3px); }

/* ==================== 列表页 ==================== */
.list-head { padding: 40px 0 6px; }
.list-head h1 { font-size: clamp(24px, 3vw, 34px); font-weight: 800; }
.list-head p { color: var(--text-muted); margin-top: 6px; font-size: 14.5px; }
.list-head p b { color: var(--accent-1); }

/* 筛选条 */
.filter-bar {
  display: flex; flex-wrap: wrap; align-items: center; gap: 16px;
  margin-top: 22px; padding: 14px 18px; background: var(--card);
  border: 1px solid var(--border); border-radius: var(--radius);
}
.chips { display: flex; flex-wrap: wrap; gap: 8px; flex: 1; }
.chip {
  padding: 6px 14px; border-radius: 999px; font-size: 13px; color: var(--text-muted);
  background: rgba(148, 163, 184, 0.07); border: 1px solid var(--border); transition: all 0.2s;
}
.chip:hover { color: var(--text); border-color: var(--border-strong); }
.chip.active { color: #fff; background: var(--gradient); border-color: transparent; font-weight: 600; }
.result-count { font-size: 13px; color: var(--text-muted); }

/* 列表容器 */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 18px; padding: 24px 0 60px; }

/* 空状态 */
.empty { text-align: center; padding: 80px 20px; color: var(--text-muted); }
.empty .big { font-size: 52px; margin-bottom: 14px; }
.empty p { font-size: 15px; }
.empty .sub { font-size: 13px; margin-top: 8px; color: rgba(139, 152, 179, 0.7); }

/* ==================== 页脚 ==================== */
.footer { position: relative; z-index: 1; border-top: 1px solid var(--border); padding: 40px 0; margin-top: 20px; }
.footer-inner { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 20px; align-items: center; }
.footer .brand { font-weight: 700; }
.footer .note { font-size: 13px; color: var(--text-muted); max-width: 520px; }
.footer .links { display: flex; gap: 18px; font-size: 13px; color: var(--text-muted); }
.footer .links a:hover { color: var(--accent-1); }

/* ==================== 响应式 ==================== */
@media (max-width: 860px) {
  .nav-search { display: none; }
  .stats-bar { flex-wrap: wrap; gap: 24px; }
  .featured-grid, .grid { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
}
@media (max-width: 560px) {
  .nav-links { gap: 2px; }
  .nav-link { padding: 6px 10px; font-size: 13px; }
}

/* 轻微入场动画 */
@keyframes fadeUp { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.fade-in { animation: fadeUp 0.45s ease both; }
@font-face {
  font-family: "iconfont"; /* Project id  */
  src: url('iconfont.ttf?t=1788858544340') format('truetype');
}

.iconfont {
  font-family: "iconfont" !important;
  font-size: 16px;
  font-style: normal;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.icon-anquan:before {
  content: "\e626";
}

.icon-jiankong:before {
  content: "\e69e";
}

.icon-qianduan:before {
  content: "\e537";
}

.icon-zhongjianjian:before {
  content: "\e63b";
}

.icon-qita:before {
  content: "\e646";
}

.icon-houduankaifa:before {
  content: "\e62a";
}

.icon-dashuju:before {
  content: "\e91f";
}

.icon-qianrushixitong:before {
  content: "\e615";
}

.icon-kaifagongju:before {
  content: "\e60e";
}

.icon-yidongduan:before {
  content: "\e653";
}

.icon-didaima:before {
  content: "\e608";
}

.icon-bianchengyuyan:before {
  content: "\e63c";
}

.icon-goujiangongju:before {
  content: "\e612";
}

.icon-odbc:before {
  content: "\e93a";
}

.icon-kaifangpingtai:before {
  content: "\e603";
}

.icon-AI:before {
  content: "\e66a";
}

.icon-yunweibushu:before {
  content: "\e668";
}

