:root {
  --bg: #17120D;
  --surface: #241C14;
  --primary: #C9A15A;
  --accent: #E84A5F;
  --text: #F4EBD9;
  --muted: #9C8B74;
  --radius: 12px;
  --border: 2px solid var(--primary);
  --shadow: 4px 4px 0 rgba(201, 161, 90, 0.35);
  --font-heading: 'Playfair Display', 'Georgia', 'Times New Roman', serif;
  --font-body: 'Inter', 'Helvetica Neue', 'PingFang SC', 'Microsoft YaHei', sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  background-image:
    radial-gradient(circle at 12% 18%, rgba(232, 74, 95, 0.06) 0, transparent 32%),
    radial-gradient(circle at 88% 72%, rgba(201, 161, 90, 0.07) 0, transparent 34%);
}

a { color: inherit; text-decoration: none; transition: color .2s, opacity .2s; }
a:hover { color: var(--primary); }
img { display: block; max-width: 100%; }
ul, ol { list-style: none; }

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

/* ===== Header ===== */
.header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(23, 18, 13, 0.94);
  backdrop-filter: blur(8px);
  border-bottom: var(--border);
  box-shadow: 0 4px 0 rgba(232, 74, 95, 0.18);
}

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

.logo {
  font-family: var(--font-heading);
  font-size: 24px;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--primary);
  white-space: nowrap;
  padding-right: 20px;
  border-right: 2px solid rgba(201, 161, 90, 0.3);
  text-shadow: 2px 2px 0 rgba(232, 74, 95, 0.5);
}

.logo:hover { color: var(--text); }

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

.nav a {
  display: inline-block;
  padding: 8px 14px;
  font-size: 14px;
  font-weight: 500;
  color: var(--muted);
  border-radius: var(--radius);
  white-space: nowrap;
  border: 2px solid transparent;
}

.nav a:hover {
  color: var(--text);
  background: var(--surface);
  border-color: var(--primary);
  transform: translateY(-2px);
  box-shadow: 3px 3px 0 rgba(201, 161, 90, 0.3);
}

.search-box {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.search-box input {
  width: 180px;
  padding: 9px 14px;
  background: var(--surface);
  border: 2px solid rgba(201, 161, 90, 0.4);
  border-radius: var(--radius);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 14px;
  outline: none;
  transition: border-color .2s, box-shadow .2s;
}

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

.search-box input:focus {
  border-color: var(--primary);
  box-shadow: 3px 3px 0 rgba(232, 74, 95, 0.4);
}

.search-box button {
  padding: 9px 18px;
  background: var(--accent);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
  border: 2px solid var(--text);
  border-radius: var(--radius);
  cursor: pointer;
  transition: transform .2s, box-shadow .2s;
}

.search-box button:hover {
  transform: translate(-2px, -2px);
  box-shadow: 4px 4px 0 var(--primary);
}

/* ===== Button ===== */
.btn {
  display: inline-block;
  padding: 10px 24px;
  background: var(--primary);
  color: var(--bg);
  font-weight: 700;
  font-size: 14px;
  border: 2px solid var(--text);
  border-radius: var(--radius);
  cursor: pointer;
  transition: transform .2s, box-shadow .2s, background .2s;
}

.btn:hover {
  color: var(--bg);
  background: var(--accent);
  transform: translate(-2px, -2px);
  box-shadow: 5px 5px 0 rgba(201, 161, 90, 0.6);
}

/* ===== Hero ===== */
.hero {
  position: relative;
  margin: 28px auto;
  border: var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  background: var(--surface);
}

.hero-slide {
  position: relative;
  display: block;
  aspect-ratio: 21 / 9;
  overflow: hidden;
}

.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .5s;
}

.hero-slide:hover img { transform: scale(1.04); }

.hero-info {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 48px 32px 28px;
  background: linear-gradient(to top, rgba(23, 18, 13, 0.96), rgba(23, 18, 13, 0.6) 55%, transparent);
}

.hero-info h2 {
  font-family: var(--font-heading);
  font-size: 30px;
  line-height: 1.25;
  margin-bottom: 8px;
  text-shadow: 2px 2px 0 rgba(232, 74, 95, 0.55);
}

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

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

.sec-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
  padding-bottom: 12px;
  border-bottom: 2px solid rgba(201, 161, 90, 0.28);
  position: relative;
}

.sec-head::before {
  content: "";
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 64px;
  height: 4px;
  background: var(--accent);
}

.sec-title {
  font-family: var(--font-heading);
  font-size: 24px;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--text);
  padding-left: 16px;
  position: relative;
}

.sec-title::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 6px;
  height: 22px;
  background: var(--primary);
  border-radius: 2px;
  box-shadow: 3px 3px 0 rgba(232, 74, 95, 0.5);
}

.sec-more {
  font-size: 13px;
  font-weight: 600;
  color: var(--primary);
  padding: 6px 14px;
  border: 2px solid var(--primary);
  border-radius: var(--radius);
  white-space: nowrap;
  transition: transform .2s, box-shadow .2s, background .2s, color .2s;
}

.sec-more:hover {
  background: var(--primary);
  color: var(--bg);
  transform: translate(-2px, -2px);
  box-shadow: 4px 4px 0 var(--accent);
}

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

.card {
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 2px solid rgba(201, 161, 90, 0.28);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform .25s, box-shadow .25s, border-color .25s;
}

.card:hover {
  transform: translate(-3px, -3px);
  border-color: var(--primary);
  box-shadow: 6px 6px 0 rgba(232, 74, 95, 0.45);
}

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

.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 9px;
  font-size: 13px;
  font-weight: 700;
  color: var(--bg);
  background: var(--primary);
  border: 2px solid var(--bg);
  border-radius: 8px;
  box-shadow: 2px 2px 0 rgba(232, 74, 95, 0.7);
}

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

.card-title {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.4;
  color: var(--text);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 6px;
  min-height: 2.8em;
}

.card-meta {
  font-size: 12px;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

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

.cat-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 16px 18px;
  background: var(--surface);
  border: 2px solid rgba(201, 161, 90, 0.3);
  border-left: 6px solid var(--accent);
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 15px;
  transition: transform .2s, box-shadow .2s, border-color .2s;
}

.cat-item:hover {
  transform: translate(-2px, -2px);
  border-color: var(--primary);
  border-left-color: var(--primary);
  box-shadow: 4px 4px 0 rgba(232, 74, 95, 0.4);
  color: var(--text);
}

.cat-count {
  font-size: 12px;
  font-weight: 700;
  color: var(--bg);
  background: var(--primary);
  padding: 1px 9px;
  border-radius: 999px;
}

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

.rank-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 16px;
  background: var(--surface);
  border: 2px solid rgba(201, 161, 90, 0.26);
  border-radius: var(--radius);
  transition: transform .2s, box-shadow .2s, border-color .2s;
}

.rank-item:hover {
  transform: translateX(4px);
  border-color: var(--primary);
  box-shadow: 4px 4px 0 rgba(232, 74, 95, 0.4);
}

.rank-num {
  flex-shrink: 0;
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-size: 17px;
  font-weight: 700;
  color: var(--bg);
  background: var(--primary);
  border: 2px solid var(--text);
  border-radius: 8px;
  box-shadow: 2px 2px 0 rgba(232, 74, 95, 0.6);
}

.rank-item:nth-child(-n+3) .rank-num { background: var(--accent); }

.rank-title {
  flex: 1;
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

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

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

.detail-head {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 32px;
  padding: 28px;
  background: var(--surface);
  border: var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.detail-cover {
  aspect-ratio: 2 / 3;
  overflow: hidden;
  border: 2px solid var(--primary);
  border-radius: var(--radius);
  background: #100c08;
}

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

.detail-meta { min-width: 0; }

.detail-meta h1 {
  font-family: var(--font-heading);
  font-size: 30px;
  line-height: 1.3;
  margin-bottom: 10px;
  text-shadow: 2px 2px 0 rgba(232, 74, 95, 0.45);
}

.detail-score {
  display: inline-block;
  margin-bottom: 16px;
  padding: 4px 14px;
  font-size: 16px;
  font-weight: 700;
  color: var(--bg);
  background: var(--primary);
  border: 2px solid var(--text);
  border-radius: 8px;
  box-shadow: 3px 3px 0 rgba(232, 74, 95, 0.6);
}

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

.detail-meta p strong { color: var(--text); font-weight: 600; }

.detail-body {
  margin-top: 28px;
  padding: 28px;
  background: var(--surface);
  border: 2px solid rgba(201, 161, 90, 0.28);
  border-radius: var(--radius);
  line-height: 1.9;
  font-size: 15px;
  color: var(--text);
}

.detail-body h2,
.detail-body h3 {
  font-family: var(--font-heading);
  color: var(--primary);
  margin: 18px 0 10px;
}

.detail-body p { margin-bottom: 12px; color: var(--muted); }

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

.tag {
  display: inline-block;
  padding: 4px 12px;
  font-size: 12px;
  font-weight: 600;
  color: var(--primary);
  background: rgba(201, 161, 90, 0.1);
  border: 2px solid rgba(201, 161, 90, 0.45);
  border-radius: 999px;
  transition: background .2s, color .2s, transform .2s;
}

.tag:hover {
  background: var(--primary);
  color: var(--bg);
  transform: translateY(-2px);
}

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

.pg {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 12px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  background: var(--surface);
  border: 2px solid rgba(201, 161, 90, 0.4);
  border-radius: var(--radius);
  transition: transform .2s, box-shadow .2s, background .2s, color .2s;
}

.pg:hover {
  color: var(--bg);
  background: var(--primary);
  border-color: var(--primary);
  transform: translate(-2px, -2px);
  box-shadow: 3px 3px 0 var(--accent);
}

.pg.current {
  color: var(--bg);
  background: var(--accent);
  border-color: var(--text);
  box-shadow: 3px 3px 0 rgba(201, 161, 90, 0.6);
  cursor: default;
}

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

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

.link-item {
  font-size: 13px;
  color: var(--muted);
  padding: 5px 12px;
  background: var(--surface);
  border: 2px solid rgba(201, 161, 90, 0.22);
  border-radius: var(--radius);
  transition: color .2s, border-color .2s, transform .2s;
}

.link-item:hover {
  color: var(--primary);
  border-color: var(--primary);
  transform: translateY(-2px);
}

/* ===== Crumbs ===== */
.crumbs {
  font-size: 13px;
  color: var(--muted);
  padding: 18px 0 0;
  line-height: 1.8;
}

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

/* ===== Highlight ===== */
.hl {
  color: var(--bg);
  background: var(--primary);
  padding: 0 3px;
  border-radius: 3px;
  font-weight: 700;
}

/* ===== Footer ===== */
.footer {
  margin-top: 56px;
  padding: 36px 0 28px;
  background: var(--surface);
  border-top: var(--border);
  box-shadow: 0 -4px 0 rgba(232, 74, 95, 0.16);
  font-size: 13px;
  color: var(--muted);
  text-align: center;
  line-height: 2;
}

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

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

@media (max-width: 768px) {
  body { font-size: 14px; }

  .wrap { padding: 0 14px; }

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

  .logo {
    font-size: 20px;
    padding-right: 0;
    border-right: none;
  }

  .nav {
    order: 3;
    width: 100%;
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 4px;
    border-top: 1px solid rgba(201, 161, 90, 0.2);
    padding-top: 8px;
  }

  .nav a { padding: 6px 12px; font-size: 13px; }

  .search-box { margin-left: auto; }
  .search-box input { width: 120px; padding: 7px 10px; font-size: 13px; }
  .search-box button { padding: 7px 12px; font-size: 13px; }

  .hero { margin: 18px auto; }
  .hero-slide { aspect-ratio: 16 / 10; }
  .hero-info { padding: 32px 18px 18px; }
  .hero-info h2 { font-size: 20px; }
  .hero-info p { font-size: 12px; -webkit-line-clamp: 2; }

  .sec { margin: 30px 0; }
  .sec-title { font-size: 19px; }
  .sec-head { margin-bottom: 16px; }

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

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

  .rank-list { grid-template-columns: 1fr; gap: 10px; }

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

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

  .detail-meta h1 { font-size: 22px; text-align: center; }
  .detail-score { display: block; width: fit-content; margin: 0 auto 14px; }

  .detail-body { padding: 18px; margin-top: 18px; }

  .pager { gap: 6px; margin: 28px 0 14px; }
  .pg { min-width: 34px; height: 34px; padding: 0 9px; font-size: 13px; }

  .footer { margin-top: 36px; padding: 24px 0 20px; font-size: 12px; }
}