:root {
  --bg: #07080C;
  --surface: #11141C;
  --primary: #5EF2E0;
  --accent: #9B6BFF;
  --text: #F2F4F8;
  --muted: #7A8290;
  --radius: 4px;
  --font-heading: "Noto Serif SC", "Songti SC", "SimSun", serif;
  --font-body: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  --line: rgba(94, 242, 224, 0.18);
  --line-soft: rgba(155, 107, 255, 0.16);
  --glass: rgba(17, 20, 28, 0.62);
  --glow: 0 0 0 1px rgba(94, 242, 224, 0.22), 0 0 18px rgba(94, 242, 224, 0.12);
  --glow-hover: 0 0 0 1px rgba(155, 107, 255, 0.55), 0 0 26px rgba(155, 107, 255, 0.28);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 14px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  background-image:
    radial-gradient(ellipse at 12% -10%, rgba(94, 242, 224, 0.10), transparent 55%),
    radial-gradient(ellipse at 88% 4%, rgba(155, 107, 255, 0.12), transparent 52%);
  background-attachment: fixed;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.035;
  background-image: radial-gradient(rgba(255, 255, 255, 0.9) 0.5px, transparent 0.5px);
  background-size: 3px 3px;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
}

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

img { display: block; max-width: 100%; }

h1, h2, h3, h4 {
  font-family: var(--font-heading);
  font-weight: 700;
  letter-spacing: 0.02em;
  margin: 0;
}

.wrap {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ============ Header ============ */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(7, 8, 12, 0.82);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}

.header .wrap {
  display: flex;
  align-items: center;
  gap: 22px;
  height: 64px;
}

.logo {
  font-family: var(--font-heading);
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 0.06em;
  white-space: nowrap;
  color: var(--text);
  text-shadow: 0 0 14px rgba(94, 242, 224, 0.35);
}

.logo img { max-height: 32px; }

.nav {
  display: flex;
  align-items: center;
  gap: 4px;
  flex: 1;
  overflow-x: auto;
  scrollbar-width: none;
}

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

.nav a {
  position: relative;
  padding: 6px 12px;
  font-size: 13px;
  color: var(--muted);
  white-space: nowrap;
  border-radius: var(--radius);
}

.nav a:hover,
.nav a.active {
  color: var(--primary);
  background: rgba(94, 242, 224, 0.06);
}

.nav a.active::after {
  content: "";
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 0;
  height: 1px;
  background: var(--primary);
  box-shadow: 0 0 8px var(--primary);
}

.search-box {
  display: flex;
  align-items: center;
  gap: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  overflow: hidden;
  flex-shrink: 0;
}

.search-box input {
  width: 150px;
  padding: 7px 10px;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 13px;
}

.search-box input::placeholder { color: var(--muted); }

.search-box button {
  padding: 7px 14px;
  border: 0;
  cursor: pointer;
  background: linear-gradient(135deg, rgba(94, 242, 224, 0.16), rgba(155, 107, 255, 0.16));
  color: var(--primary);
  font-family: var(--font-body);
  font-size: 13px;
  border-left: 1px solid var(--line);
  transition: background 0.2s ease;
}

.search-box button:hover {
  background: linear-gradient(135deg, rgba(94, 242, 224, 0.28), rgba(155, 107, 255, 0.28));
}

/* ============ Hero ============ */
.hero {
  position: relative;
  margin: 24px 0 36px;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: var(--glow);
  background: var(--surface);
}

.hero-slide {
  position: relative;
  display: none;
  aspect-ratio: 21 / 9;
  min-height: 260px;
}

.hero-slide.active,
.hero-slide:first-child { display: block; }

.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.62;
}

.hero-info {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 40px 32px 28px;
  background: linear-gradient(to top, rgba(7, 8, 12, 0.96), rgba(7, 8, 12, 0.4) 60%, transparent);
}

.hero-info h2 {
  font-size: 26px;
  margin-bottom: 8px;
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.8);
}

.hero-info p {
  margin: 0 0 14px;
  max-width: 640px;
  color: var(--muted);
  font-size: 13px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.btn {
  display: inline-block;
  padding: 8px 22px;
  border-radius: var(--radius);
  border: 1px solid var(--primary);
  color: var(--primary);
  font-size: 13px;
  letter-spacing: 0.08em;
  background: rgba(94, 242, 224, 0.06);
  transition: all 0.22s ease;
}

.btn:hover {
  color: var(--bg);
  background: var(--primary);
  box-shadow: 0 0 20px rgba(94, 242, 224, 0.45);
}

/* ============ Section ============ */
.sec { margin-bottom: 40px; }

.sec-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 10px;
  margin-bottom: 18px;
  border-bottom: 1px solid var(--line);
  position: relative;
}

.sec-head::before {
  content: "";
  position: absolute;
  left: 0;
  bottom: -1px;
  width: 46px;
  height: 2px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  box-shadow: 0 0 10px rgba(94, 242, 224, 0.6);
}

.sec-title {
  font-size: 19px;
  letter-spacing: 0.06em;
  padding-left: 14px;
  position: relative;
}

.sec-title::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 3px;
  height: 16px;
  background: var(--accent);
  box-shadow: 0 0 8px var(--accent);
}

.sec-more {
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.1em;
  white-space: nowrap;
}

.sec-more:hover { color: var(--primary); }

/* ============ Grid & Card ============ */
.grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 18px;
}

.card {
  position: relative;
  border-radius: var(--radius);
  background: var(--glass);
  border: 1px solid var(--line-soft);
  overflow: hidden;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.card:hover {
  transform: translateY(-5px);
  border-color: rgba(94, 242, 224, 0.5);
  box-shadow: var(--glow-hover);
}

.card-cover {
  position: relative;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: #0b0d12;
}

.card-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.card:hover .card-cover img { transform: scale(1.05); }

.card-score {
  position: absolute;
  top: 8px;
  right: 8px;
  padding: 2px 7px;
  font-size: 12px;
  font-weight: 700;
  color: var(--bg);
  background: linear-gradient(135deg, var(--primary), var(--accent));
  border-radius: var(--radius);
  box-shadow: 0 0 12px rgba(94, 242, 224, 0.5);
}

.card-info { padding: 10px 10px 12px; }

.card-title {
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.4;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 5px;
}

.card-meta {
  font-size: 11px;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  letter-spacing: 0.03em;
}

/* ============ Cat list ============ */
.cat-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.cat-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 15px;
  font-size: 13px;
  border-radius: var(--radius);
  border: 1px solid var(--line-soft);
  background: var(--surface);
  color: var(--text);
  transition: all 0.22s ease;
}

.cat-item:hover {
  border-color: var(--primary);
  color: var(--primary);
  box-shadow: var(--glow);
}

.cat-count {
  font-size: 11px;
  color: var(--muted);
  padding: 0 5px;
  border-radius: 2px;
  background: rgba(155, 107, 255, 0.12);
}

/* ============ Rank list ============ */
.rank-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0 32px;
}

.rank-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 0;
  border-bottom: 1px dashed rgba(122, 130, 144, 0.18);
  transition: padding-left 0.22s ease;
}

.rank-item:hover { padding-left: 6px; }

.rank-num {
  flex-shrink: 0;
  width: 26px;
  font-family: var(--font-heading);
  font-size: 18px;
  font-style: italic;
  font-weight: 700;
  text-align: center;
  color: var(--muted);
}

.rank-item:nth-child(1) .rank-num,
.rank-item:nth-child(2) .rank-num,
.rank-item:nth-child(3) .rank-num {
  color: var(--primary);
  text-shadow: 0 0 12px rgba(94, 242, 224, 0.6);
}

.rank-title {
  flex: 1;
  min-width: 0;
  font-size: 13px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.rank-score {
  flex-shrink: 0;
  font-size: 12px;
  font-weight: 700;
  color: var(--accent);
}

/* ============ Detail ============ */
.detail { margin: 24px 0 40px; }

.detail-head {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 28px;
  padding: 24px;
  border-radius: var(--radius);
  background: var(--glass);
  border: 1px solid var(--line);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: var(--glow);
}

.detail-cover {
  aspect-ratio: 2 / 3;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line-soft);
}

.detail-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.detail-meta h1 {
  font-size: 26px;
  margin-bottom: 6px;
  line-height: 1.3;
}

.detail-meta p {
  margin: 0 0 8px;
  font-size: 13px;
  color: var(--muted);
}

.detail-meta p strong {
  color: var(--text);
  font-weight: 500;
  margin-right: 4px;
}

.detail-score {
  display: inline-block;
  margin: 10px 0 14px;
  font-family: var(--font-heading);
  font-size: 30px;
  font-weight: 700;
  color: var(--primary);
  text-shadow: 0 0 18px rgba(94, 242, 224, 0.55);
}

.detail-score small {
  font-size: 13px;
  color: var(--muted);
  margin-left: 4px;
}

.detail-body {
  margin-top: 26px;
  padding: 22px 24px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--line-soft);
  font-size: 14px;
  line-height: 1.9;
  color: rgba(242, 244, 248, 0.86);
}

.detail-body h2,
.detail-body h3 {
  font-size: 17px;
  margin: 20px 0 10px;
  padding-left: 12px;
  border-left: 3px solid var(--accent);
}

.detail-body p { margin: 0 0 12px; }

/* ============ Tags ============ */
.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.tag {
  display: inline-block;
  padding: 3px 10px;
  font-size: 12px;
  color: var(--primary);
  border: 1px solid rgba(94, 242, 224, 0.3);
  border-radius: var(--radius);
  background: rgba(94, 242, 224, 0.05);
  transition: all 0.2s ease;
}

.tag:hover {
  color: var(--bg);
  background: var(--primary);
  box-shadow: 0 0 14px rgba(94, 242, 224, 0.5);
}

/* ============ Pager ============ */
.pager {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 8px;
  margin: 36px 0 12px;
}

.pg {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 12px;
  font-size: 13px;
  border-radius: var(--radius);
  border: 1px solid var(--line-soft);
  background: var(--surface);
  color: var(--muted);
  transition: all 0.2s ease;
}

.pg:hover {
  color: var(--primary);
  border-color: var(--primary);
  box-shadow: var(--glow);
}

.pg.current {
  color: var(--bg);
  font-weight: 700;
  border-color: transparent;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  box-shadow: 0 0 18px rgba(94, 242, 224, 0.4);
}

.pg.disabled {
  opacity: 0.35;
  pointer-events: none;
  cursor: not-allowed;
}

/* ============ Links ============ */
.links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  padding: 18px 0;
  border-top: 1px solid var(--line-soft);
}

.link-item {
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.04em;
}

.link-item:hover { color: var(--primary); }

/* ============ Footer ============ */
.footer {
  margin-top: 40px;
  padding: 28px 0 34px;
  border-top: 1px solid var(--line);
  background: rgba(17, 20, 28, 0.5);
  font-size: 12px;
  color: var(--muted);
  text-align: center;
  line-height: 2;
}

.footer a { color: var(--muted); }
.footer a:hover { color: var(--primary); }

/* ============ Crumbs ============ */
.crumbs {
  padding: 14px 0;
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.05em;
}

.crumbs a { color: var(--muted); }
.crumbs a:hover { color: var(--primary); }
.crumbs span { color: var(--primary); }

/* ============ Highlight ============ */
.hl {
  color: var(--bg);
  background: linear-gradient(135deg, var(--primary), var(--accent));
  padding: 0 3px;
  border-radius: 2px;
  font-style: normal;
}

/* ============ Responsive ============ */
@media (max-width: 1024px) {
  .grid { grid-template-columns: repeat(4, 1fr); }
  .rank-list { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  .wrap { padding: 0 14px; }

  .header .wrap {
    height: auto;
    flex-wrap: wrap;
    gap: 10px;
    padding-top: 10px;
    padding-bottom: 10px;
  }

  .logo { font-size: 17px; }

  .nav {
    order: 3;
    width: 100%;
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 2px;
    -webkit-overflow-scrolling: touch;
  }

  .nav a { padding: 5px 10px; font-size: 12px; }

  .search-box { margin-left: auto; }
  .search-box input { width: 110px; }

  .hero { margin: 14px 0 26px; }
  .hero-slide { aspect-ratio: 4 / 3; min-height: 200px; }
  .hero-info { padding: 24px 16px 18px; }
  .hero-info h2 { font-size: 19px; }
  .hero-info p { font-size: 12px; -webkit-line-clamp: 2; }

  .sec { margin-bottom: 28px; }
  .sec-title { font-size: 16px; }

  .grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .card-info { padding: 8px 8px 10px; }
  .card-title { font-size: 13px; }

  .cat-item { padding: 6px 12px; font-size: 12px; }

  .rank-item { padding: 10px 0; gap: 10px; }
  .rank-num { width: 22px; font-size: 15px; }

  .detail-head {
    grid-template-columns: 1fr;
    gap: 16px;
    padding: 16px;
  }

  .detail-cover {
    max-width: 180px;
    margin: 0 auto;
  }

  .detail-meta h1 { font-size: 20px; text-align: center; }
  .detail-meta p { text-align: center; }
  .detail-score { display: block; text-align: center; margin: 8px 0 12px; }

  .detail-body { padding: 16px; font-size: 13px; }

  .pg { min-width: 32px; height: 32px; padding: 0 9px; font-size: 12px; }

  .footer { font-size: 11px; padding: 20px 0 26px; }
}