:root {
  --bg: #f4f7fb;
  --surface: #ffffff;
  --surface-soft: #f8fbff;
  --text: #1f2937;
  --muted: #64748b;
  --line: #e7edf4;
  --primary: #2f7cf6;
  --primary-soft: #eaf2ff;
  --shadow: 0 16px 38px rgba(31, 45, 80, 0.08);
  --radius-lg: 18px;
  --radius-md: 14px;
  --radius-sm: 12px;
  --max-width: 1360px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(47, 124, 246, 0.08), transparent 24%),
    radial-gradient(circle at top right, rgba(20, 184, 106, 0.08), transparent 18%),
    var(--bg);
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(16px);
  box-shadow: 0 8px 24px rgba(31, 45, 80, 0.05);
}

.utility-bar {
  background: #f8fafc;
  border-bottom: 1px solid rgba(231, 237, 244, 0.9);
}

.utility-inner,
.site-header-inner,
.subnav-inner,
.page-shell,
.site-footer {
  width: min(calc(100% - 32px), var(--max-width));
  margin: 0 auto;
}

.utility-inner {
  min-height: 36px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  color: var(--muted);
  font-size: 12px;
}

.utility-links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.utility-links a:hover {
  color: var(--primary);
}

.utility-links a.active {
  color: var(--primary);
  font-weight: 700;
}

.site-header-main {
  border-bottom: 1px solid rgba(231, 237, 244, 0.9);
}

.site-header-inner {
  min-height: 68px;
  display: flex;
  align-items: center;
  gap: 18px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: fit-content;
}

.brand-mark {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: var(--primary);
  font-weight: 700;
  font-size: 16px;
  background: linear-gradient(135deg, #eff6ff, #dbeafe);
  border: 1px solid #bfdbfe;
}

.brand-copy strong {
  display: block;
  font-size: 17px;
}

.brand-copy span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
}

.top-nav {
  display: flex;
  align-items: center;
  gap: 0;
  margin-left: 8px;
}

.top-nav a {
  position: relative;
  padding: 23px 13px 19px;
  color: #334155;
  font-size: 14px;
  font-weight: 600;
}

.top-nav a::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 10px;
  height: 2px;
  border-radius: 999px;
  background: transparent;
}

.top-nav a:hover,
.top-nav a.active {
  color: var(--primary);
}

.top-nav a:hover::after,
.top-nav a.active::after {
  background: var(--primary);
}

.header-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 10px;
}

.header-link,
.header-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 14px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
}

.header-link {
  color: #334155;
  border: 1px solid #e5edf6;
  background: #f8fafc;
}

.header-primary {
  color: white;
  background: linear-gradient(135deg, #2f7cf6, #4e9cff);
}

.subnav {
  border-bottom: 1px solid rgba(231, 237, 244, 0.9);
}

.subnav-inner {
  display: flex;
  align-items: center;
  gap: 18px;
  overflow-x: auto;
  padding: 14px 0;
  scrollbar-width: none;
}

.subnav-inner::-webkit-scrollbar {
  display: none;
}

.subnav a {
  white-space: nowrap;
  color: #475569;
  font-size: 13px;
  font-weight: 600;
}

.subnav a:hover,
.subnav a.active {
  color: var(--primary);
}

.page-shell {
  padding: 24px 0 42px;
}

.panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}

.hero-simple {
  padding: 24px;
  background:
    radial-gradient(circle at top right, rgba(47, 124, 246, 0.15), transparent 30%),
    linear-gradient(180deg, #ffffff, #f8fbff);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(47, 124, 246, 0.08);
  color: var(--primary);
  font-size: 12px;
  font-weight: 700;
}

.hero-simple h1 {
  margin: 16px 0 10px;
  font-size: clamp(28px, 3vw, 40px);
  line-height: 1.1;
}

.hero-simple p {
  max-width: 820px;
  margin: 0;
  color: var(--muted);
  line-height: 1.75;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}

.hero-actions a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 16px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  border: 1px solid #e5edf6;
  background: white;
}

.hero-actions a.primary {
  color: white;
  border: 0;
  background: linear-gradient(135deg, #2f7cf6, #4e9cff);
}

.stats-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.stat-card {
  padding: 16px;
  border-radius: var(--radius-md);
  border: 1px solid var(--line);
  background: white;
}

.stat-card strong {
  display: block;
  font-size: 24px;
  margin-bottom: 6px;
}

.stat-card span {
  color: var(--muted);
  font-size: 12px;
}

.layout-stack {
  display: grid;
  gap: 18px;
  margin-top: 18px;
}

.section {
  padding: 18px;
}

.section-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}

.section-copy h2 {
  margin: 0;
  font-size: 20px;
}

.section-copy p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.section-side {
  display: flex;
  align-items: center;
  gap: 10px;
}

.section-side a {
  color: #64748b;
  font-size: 13px;
  font-weight: 600;
}

.section-side a:hover {
  color: var(--primary);
}

.badge {
  padding: 7px 11px;
  border-radius: 999px;
  background: var(--surface-soft);
  border: 1px solid #edf3fa;
  color: #607089;
  font-size: 12px;
}

.tool-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.compact-tool-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
}

.compact-tool-card {
  display: block;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: white;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.compact-tool-card:hover {
  transform: translateY(-2px);
  border-color: rgba(47, 124, 246, 0.16);
  box-shadow: 0 12px 22px rgba(31, 45, 80, 0.08);
}

.compact-tool-head {
  display: flex;
  align-items: center;
  gap: 10px;
}

.compact-tool-logo {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  overflow: hidden;
  background: white;
  border: 1px solid #e8eef6;
  box-shadow: 0 6px 14px rgba(15, 23, 42, 0.06);
}

.compact-tool-logo img {
  width: 24px;
  height: 24px;
  object-fit: contain;
}

.compact-tool-copy {
  min-width: 0;
}

.compact-tool-copy strong {
  display: block;
  margin-bottom: 4px;
  font-size: 15px;
}

.compact-tool-copy span {
  display: -webkit-box;
  overflow: hidden;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.tool-card {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: white;
  display: grid;
  gap: 10px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.tool-card:hover {
  transform: translateY(-2px);
  border-color: rgba(47, 124, 246, 0.16);
  box-shadow: 0 12px 22px rgba(31, 45, 80, 0.08);
}

.tool-top {
  display: flex;
  align-items: center;
  gap: 10px;
}

.tool-logo {
  position: relative;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  overflow: hidden;
  background: white;
  border: 1px solid #e8eef6;
  box-shadow: 0 6px 14px rgba(15, 23, 42, 0.06);
}

.tool-logo img {
  width: 24px;
  height: 24px;
  object-fit: contain;
}

.tool-title {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.tool-title h3 {
  margin: 0;
  font-size: 15px;
}

.tool-meta {
  color: var(--muted);
  font-size: 12px;
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  align-items: center;
}

.tool-desc {
  margin: 0;
  color: #556274;
  font-size: 13px;
  line-height: 1.55;
}

.pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.pill {
  padding: 4px 8px;
  border-radius: 999px;
  background: #f4f7fb;
  color: #607089;
  font-size: 11px;
}

.tool-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.tool-foot a {
  color: var(--primary);
  font-size: 13px;
  font-weight: 600;
}

.status {
  font-size: 11px;
  padding: 5px 8px;
  border-radius: 999px;
  font-weight: 600;
}

.status.hot {
  color: #d97706;
  background: rgba(255, 159, 67, 0.14);
}

.status.new {
  color: #0f9e57;
  background: rgba(20, 184, 106, 0.14);
}

.status.pick {
  color: var(--primary);
  background: rgba(47, 124, 246, 0.12);
}

.rank-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.rank-card {
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 14px;
  background: linear-gradient(180deg, #ffffff, #fbfdff);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.rank-card:hover {
  transform: translateY(-2px);
  border-color: rgba(47, 124, 246, 0.16);
  box-shadow: 0 12px 22px rgba(31, 45, 80, 0.08);
}

.rank-card h3 {
  margin: 0 0 12px;
  font-size: 15px;
}

.rank-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.rank-list li {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  gap: 10px;
}

.rank-num {
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: #f1f5f9;
  color: #475569;
  font-size: 12px;
  font-weight: 700;
}

.rank-list li:nth-child(-n+3) .rank-num {
  background: #eff6ff;
  color: var(--primary);
}

.rank-item strong,
.topic-card strong,
.info-card strong {
  display: block;
  margin-bottom: 4px;
  font-size: 14px;
}

.rank-item span,
.topic-card span,
.info-card span,
.info-card p {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
}

.topic-grid,
.info-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.topic-card,
.info-card {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: linear-gradient(180deg, #ffffff, #fbfdff);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.topic-card:hover,
.info-card:hover {
  transform: translateY(-2px);
  border-color: rgba(47, 124, 246, 0.16);
  box-shadow: 0 12px 22px rgba(31, 45, 80, 0.08);
}

.topic-meta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 10px;
  padding: 5px 8px;
  border-radius: 999px;
  background: #eff6ff;
  color: var(--primary);
  font-size: 11px;
  font-weight: 700;
}

.link-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.link-cloud a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #fbfdff;
  color: #475569;
  font-size: 12px;
  font-weight: 600;
}

.link-cloud a:hover {
  color: var(--primary);
  background: #eff6ff;
}

.anchor-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.anchor-nav a {
  padding: 8px 12px;
  border-radius: 999px;
  background: white;
  border: 1px solid var(--line);
  color: #475569;
  font-size: 12px;
  font-weight: 600;
}

.anchor-nav a:hover {
  color: var(--primary);
  background: #eff6ff;
}

.site-footer {
  padding: 18px 0 36px;
  border-top: 1px solid rgba(231, 237, 244, 0.9);
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  color: #7b8797;
  font-size: 13px;
}

@media (max-width: 1240px) {
  .tool-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .compact-tool-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (max-width: 1080px) {
  .rank-grid,
  .topic-grid,
  .info-grid,
  .stats-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .compact-tool-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 860px) {
  .utility-inner,
  .site-header-inner {
    width: min(calc(100% - 20px), var(--max-width));
  }

  .utility-inner {
    min-height: auto;
    padding: 8px 0;
    align-items: flex-start;
    flex-direction: column;
  }

  .site-header-inner {
    min-height: auto;
    flex-wrap: wrap;
    padding: 10px 0;
  }

  .top-nav {
    width: 100%;
    overflow-x: auto;
    margin-left: 0;
    flex-wrap: nowrap;
    scrollbar-width: none;
  }

  .top-nav::-webkit-scrollbar {
    display: none;
  }

  .top-nav a {
    white-space: nowrap;
    padding: 14px 10px 18px;
  }

  .header-actions {
    margin-left: 0;
  }

  .tool-grid,
  .compact-tool-grid,
  .rank-grid,
  .topic-grid,
  .info-grid,
  .stats-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 620px) {
  .page-shell,
  .site-footer {
    width: min(calc(100% - 20px), var(--max-width));
  }

  .hero-simple,
  .section {
    padding: 18px;
  }

  .tool-grid,
  .compact-tool-grid,
  .rank-grid,
  .topic-grid,
  .info-grid,
  .stats-row {
    grid-template-columns: 1fr;
  }

  .hero-simple h1 {
    font-size: 28px;
  }
}
