:root {
  --bg: #0D0A14;
  --surface: #1A1225;
  --primary: #FF4FCB;
  --accent: #7B5CFF;
  --text: #F0E9FF;
  --muted: #9B8FB8;
  --radius: 14px;
  --font-heading: 'Noto Serif SC', 'Songti SC', serif;
  --font-body: 'Inter', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  --border: rgba(123, 92, 255, 0.35);
  --glow: 0 0 12px rgba(255, 79, 203, 0.45);
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 14px;
  line-height: 1.6;
  background-image:
    radial-gradient(ellipse at 15% 0%, rgba(123, 92, 255, 0.18), transparent 55%),
    radial-gradient(ellipse at 85% 100%, rgba(255, 79, 203, 0.14), transparent 55%),
    repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.015) 0 1px, transparent 1px 3px);
  background-attachment: fixed;
  min-height: 100vh;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
ul, ol { list-style: none; }

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

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

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

.logo {
  font-family: var(--font-heading);
  font-size: 22px;
  font-weight: 700;
  letter-spacing: 1px;
  white-space: nowrap;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 0 18px rgba(255, 79, 203, 0.35);
}

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

.nav a {
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 13px;
  color: var(--muted);
  white-space: nowrap;
  transition: color .2s, background .2s, box-shadow .2s;
}
.nav a:hover {
  color: var(--text);
  background: rgba(123, 92, 255, 0.18);
  box-shadow: inset 0 0 0 1px var(--border);
}

.search-box {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(26, 18, 37, 0.9);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 4px 6px 4px 14px;
  transition: box-shadow .2s, border-color .2s;
}
.search-box:focus-within {
  border-color: var(--primary);
  box-shadow: var(--glow);
}
.search-box input {
  background: transparent;
  border: none;
  outline: none;
  color: var(--text);
  font-size: 13px;
  width: 140px;
  font-family: var(--font-body);
}
.search-box input::placeholder { color: var(--muted); }
.search-box button {
  background: linear-gradient(135deg, var(--primary), var(--accent));
  border: none;
  color: #fff;
  font-size: 12px;
  padding: 5px 14px;
  border-radius: 999px;
  cursor: pointer;
  font-family: var(--font-body);
  transition: filter .2s;
}
.search-box button:hover { filter: brightness(1.15); }

/* ============ Hero ============ */
.hero {
  position: relative;
  margin: 24px 0;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: 0 0 30px rgba(123, 92, 255, 0.18);
}

.hero-slide {
  position: relative;
  aspect-ratio: 21 / 9;
  min-height: 240px;
  background: var(--surface);
  overflow: hidden;
}
.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.55;
}
.hero-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(13, 10, 20, 0.92) 0%, rgba(13, 10, 20, 0.35) 55%, transparent 100%);
}

.hero-info {
  position: absolute;
  left: 0;
  bottom: 0;
  z-index: 2;
  padding: 28px 32px;
  max-width: 560px;
}
.hero-info h2 {
  font-family: var(--font-heading);
  font-size: 30px;
  line-height: 1.25;
  margin-bottom: 8px;
  background: linear-gradient(90deg, #fff, var(--primary));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero-info p {
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 16px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 22px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  box-shadow: 0 0 16px rgba(255, 79, 203, 0.4);
  transition: transform .2s, filter .2s;
  border: none;
  cursor: pointer;
}
.btn:hover { transform: translateY(-2px); filter: brightness(1.12); }

/* ============ Section ============ */
.sec { margin: 36px 0; }

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

.sec-title {
  font-family: var(--font-heading);
  font-size: 20px;
  font-weight: 700;
  position: relative;
  padding-left: 14px;
  letter-spacing: .5px;
}
.sec-title::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 18px;
  border-radius: 2px;
  background: linear-gradient(180deg, var(--primary), var(--accent));
  box-shadow: 0 0 8px var(--primary);
}

.sec-more {
  font-size: 12px;
  color: var(--muted);
  transition: color .2s;
}
.sec-more:hover { color: var(--primary); }

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

.card {
  background: var(--surface);
  border: 1px solid transparent;
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform .25s, box-shadow .25s, border-color .25s;
  position: relative;
}
.card:hover {
  transform: translateY(-6px);
  border-color: var(--border);
  box-shadow: 0 10px 28px rgba(123, 92, 255, 0.28), 0 0 14px rgba(255, 79, 203, 0.18);
}

.card-cover {
  position: relative;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: #0a0710;
}
.card-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .4s;
}
.card:hover .card-cover img { transform: scale(1.06); }

.card-score {
  position: absolute;
  top: 8px;
  right: 8px;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  color: #fff;
  background: rgba(13, 10, 20, 0.72);
  border: 1px solid var(--primary);
  box-shadow: 0 0 10px rgba(255, 79, 203, 0.5);
  backdrop-filter: blur(4px);
}

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

.card-title {
  font-size: 13px;
  font-weight: 600;
  line-height: 1.4;
  color: var(--text);
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color .2s;
}
.card:hover .card-title { color: var(--primary); }

.card-meta {
  margin-top: 4px;
  font-size: 11px;
  color: var(--muted);
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ============ Cat list ============ */
.cat-list {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 12px;
}

.cat-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 16px 8px;
  border-radius: var(--radius);
  background: rgba(26, 18, 37, 0.7);
  border: 1px solid var(--border);
  font-size: 13px;
  text-align: center;
  transition: transform .2s, box-shadow .2s, background .2s;
}
.cat-item:hover {
  transform: translateY(-3px);
  background: rgba(123, 92, 255, 0.16);
  box-shadow: 0 0 16px rgba(255, 79, 203, 0.25);
  color: var(--primary);
}

.cat-count {
  font-size: 11px;
  color: var(--muted);
}

/* ============ Rank list ============ */
.rank-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.rank-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 14px;
  border-radius: var(--radius);
  background: rgba(26, 18, 37, 0.6);
  border: 1px solid transparent;
  transition: background .2s, border-color .2s, transform .2s;
}
.rank-item:hover {
  background: rgba(123, 92, 255, 0.14);
  border-color: var(--border);
  transform: translateX(4px);
}

.rank-num {
  flex: 0 0 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 15px;
  color: var(--muted);
  background: rgba(13, 10, 20, 0.6);
}
.rank-item:nth-child(1) .rank-num,
.rank-item:nth-child(2) .rank-num,
.rank-item:nth-child(3) .rank-num {
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  box-shadow: 0 0 12px rgba(255, 79, 203, 0.45);
}

.rank-title {
  flex: 1;
  font-size: 13px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  transition: color .2s;
}
.rank-item:hover .rank-title { color: var(--primary); }

.rank-score {
  font-size: 13px;
  font-weight: 700;
  color: var(--primary);
  text-shadow: 0 0 8px rgba(255, 79, 203, 0.5);
}

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

.detail-head {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 28px;
  padding: 24px;
  border-radius: var(--radius);
  background: rgba(26, 18, 37, 0.6);
  border: 1px solid var(--border);
  backdrop-filter: blur(8px);
}

.detail-cover {
  aspect-ratio: 2 / 3;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: 0 0 24px rgba(123, 92, 255, 0.3);
}
.detail-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.detail-meta {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.detail-meta h1 {
  font-family: var(--font-heading);
  font-size: 26px;
  line-height: 1.3;
  background: linear-gradient(90deg, #fff, var(--primary));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.detail-meta p {
  font-size: 13px;
  color: var(--muted);
}
.detail-meta p strong { color: var(--text); font-weight: 600; }

.detail-score {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  font-family: var(--font-heading);
  font-size: 32px;
  font-weight: 700;
  color: var(--primary);
  text-shadow: 0 0 16px rgba(255, 79, 203, 0.6);
}
.detail-score small { font-size: 13px; color: var(--muted); text-shadow: none; }

.detail-body {
  margin-top: 24px;
  padding: 24px;
  border-radius: var(--radius);
  background: rgba(26, 18, 37, 0.5);
  border: 1px solid var(--border);
  font-size: 14px;
  line-height: 1.9;
  color: var(--text);
}
.detail-body h2 {
  font-family: var(--font-heading);
  font-size: 18px;
  margin: 18px 0 10px;
  color: var(--primary);
}
.detail-body h2:first-child { margin-top: 0; }
.detail-body p { margin-bottom: 12px; color: #d8cfe8; }

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

.tag {
  padding: 3px 12px;
  border-radius: 999px;
  font-size: 12px;
  color: var(--muted);
  background: rgba(123, 92, 255, 0.12);
  border: 1px solid var(--border);
  transition: color .2s, background .2s, box-shadow .2s;
}
.tag:hover {
  color: var(--text);
  background: rgba(255, 79, 203, 0.18);
  box-shadow: 0 0 10px rgba(255, 79, 203, 0.3);
}

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

.pg {
  min-width: 36px;
  height: 36px;
  padding: 0 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  font-size: 13px;
  color: var(--muted);
  background: rgba(26, 18, 37, 0.8);
  border: 1px solid var(--border);
  transition: all .2s;
}
.pg:hover {
  color: var(--text);
  border-color: var(--primary);
  box-shadow: 0 0 10px rgba(255, 79, 203, 0.3);
}
.pg.current {
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  border-color: transparent;
  box-shadow: 0 0 14px rgba(255, 79, 203, 0.5);
}
.pg.disabled {
  opacity: 0.35;
  pointer-events: none;
}

/* ============ Links ============ */
.links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  padding: 18px 0;
}

.link-item {
  font-size: 12px;
  color: var(--muted);
  transition: color .2s;
}
.link-item:hover { color: var(--primary); }

/* ============ Footer ============ */
.footer {
  margin-top: 48px;
  padding: 28px 0 36px;
  border-top: 1px solid var(--border);
  text-align: center;
  font-size: 12px;
  color: var(--muted);
  background: linear-gradient(180deg, transparent, rgba(123, 92, 255, 0.06));
}
.footer a { color: var(--muted); transition: color .2s; }
.footer a:hover { color: var(--primary); }
.footer p { margin: 4px 0; }

/* ============ Crumbs ============ */
.crumbs {
  padding: 16px 0 0;
  font-size: 12px;
  color: var(--muted);
}
.crumbs a { color: var(--muted); transition: color .2s; }
.crumbs a:hover { color: var(--primary); }
.crumbs span { color: var(--text); }

/* ============ Highlight ============ */
.hl {
  color: var(--primary);
  font-style: normal;
  text-shadow: 0 0 8px rgba(255, 79, 203, 0.5);
}

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

@media (max-width: 768px) {
  .header .wrap {
    height: auto;
    flex-wrap: wrap;
    gap: 10px;
    padding-top: 10px;
    padding-bottom: 10px;
  }
  .logo { font-size: 19px; }
  .nav {
    order: 3;
    width: 100%;
    flex: 0 0 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 2px;
  }
  .search-box { margin-left: auto; }
  .search-box input { width: 100px; }

  .hero-slide { aspect-ratio: 16 / 10; min-height: 200px; }
  .hero-info { padding: 18px 20px; max-width: 100%; }
  .hero-info h2 { font-size: 20px; }
  .hero-info p { font-size: 12px; -webkit-line-clamp: 2; }

  .sec { margin: 26px 0; }
  .sec-title { font-size: 17px; }

  .grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .cat-list { grid-template-columns: repeat(3, 1fr); gap: 8px; }
  .cat-item { padding: 12px 6px; font-size: 12px; }

  .detail-head {
    grid-template-columns: 1fr;
    gap: 18px;
    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 { justify-content: center; width: 100%; }
  .detail-body { padding: 16px; font-size: 13px; }

  .rank-item { padding: 8px 10px; gap: 10px; }
  .rank-num { flex: 0 0 26px; height: 26px; font-size: 13px; }
  .rank-title { font-size: 12px; }

  .pager { gap: 6px; }
  .pg { min-width: 32px; height: 32px; padding: 0 10px; font-size: 12px; }
}