:root {
  --bg: #0A0A0C;
  --surface: #15151A;
  --primary: #00E5C0;
  --accent: #B36BFF;
  --text: #F0F0F5;
  --muted: #8A8A9A;
  --radius: 16px;
  --font-heading: 'Syne', 'Helvetica Neue', Arial, sans-serif;
  --font-body: 'Inter', 'Segoe UI', Roboto, sans-serif;
  --glass: rgba(21, 21, 26, 0.6);
  --border: rgba(255, 255, 255, 0.08);
  --shadow-primary: 0 0 24px rgba(0, 229, 192, 0.25);
  --shadow-accent: 0 0 24px rgba(179, 107, 255, 0.25);
}

* { 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;
  min-height: 100vh;
}

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

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: .01em;
}

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

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

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

.logo {
  font-family: var(--font-heading);
  font-size: 22px;
  font-weight: 800;
  letter-spacing: .04em;
  color: var(--text);
  white-space: nowrap;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.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;
  color: var(--muted);
  border-radius: 999px;
  white-space: nowrap;
  transition: all .25s ease;
}
.nav a:hover,
.nav a.active {
  color: var(--primary);
  background: rgba(0, 229, 192, 0.08);
  box-shadow: inset 0 0 0 1px rgba(0, 229, 192, 0.25);
}

.search-box {
  position: relative;
  flex-shrink: 0;
}
.search-box input {
  width: 200px;
  height: 38px;
  padding: 0 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 14px;
  outline: none;
  transition: all .25s ease;
}
.search-box input::placeholder { color: var(--muted); }
.search-box input:focus {
  border-color: var(--primary);
  box-shadow: var(--shadow-primary);
  width: 240px;
}
.search-box button {
  position: absolute;
  right: 4px;
  top: 4px;
  width: 30px;
  height: 30px;
  border: none;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: #0A0A0C;
  font-weight: 700;
  cursor: pointer;
  transition: transform .2s ease;
}
.search-box button:hover { transform: scale(1.08); }

/* ============ Hero ============ */
.hero {
  position: relative;
  margin: 28px 0 48px;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--surface);
  box-shadow: 0 0 0 1px var(--border), 0 24px 60px rgba(0, 0, 0, 0.6);
}

.hero-slide {
  position: relative;
  display: block;
  aspect-ratio: 21 / 9;
  overflow: hidden;
}
.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .6s ease;
}
.hero-slide:hover img { transform: scale(1.04); }
.hero-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(10,10,12,.92) 0%, rgba(10,10,12,.5) 45%, transparent 75%),
              linear-gradient(0deg, rgba(10,10,12,.9) 0%, transparent 55%);
}

.hero-info {
  position: absolute;
  left: 0;
  bottom: 0;
  z-index: 2;
  padding: 40px;
  max-width: 60%;
}
.hero-info h2 {
  font-size: 34px;
  margin-bottom: 10px;
  text-shadow: 0 2px 24px rgba(0, 0, 0, 0.8);
}
.hero-info p {
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 18px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ============ Buttons ============ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 24px;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
  color: #0A0A0C;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  border: none;
  border-radius: 999px;
  cursor: pointer;
  transition: transform .2s ease, box-shadow .25s ease;
  box-shadow: var(--shadow-primary);
}
.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 32px rgba(179, 107, 255, 0.5);
  color: #0A0A0C;
}
.btn.ghost {
  background: transparent;
  color: var(--primary);
  box-shadow: inset 0 0 0 1px var(--primary);
}
.btn.ghost:hover {
  background: rgba(0, 229, 192, 0.1);
  box-shadow: inset 0 0 0 1px var(--primary), var(--shadow-primary);
}

/* ============ Sections ============ */
.sec { margin-bottom: 56px; }

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

.sec-title {
  position: relative;
  font-size: 22px;
  padding-left: 16px;
}
.sec-title::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 22px;
  border-radius: 2px;
  background: linear-gradient(180deg, var(--primary), var(--accent));
  box-shadow: var(--shadow-primary);
}

.sec-more {
  font-size: 13px;
  color: var(--muted);
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid var(--border);
  transition: all .25s ease;
}
.sec-more:hover {
  color: var(--primary);
  border-color: var(--primary);
  box-shadow: var(--shadow-primary);
}

/* ============ Grid & Cards ============ */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 22px;
}

.card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--glass);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform .3s ease, box-shadow .3s ease, border-color .3s ease;
}
.card:hover {
  transform: translateY(-6px);
  border-color: rgba(0, 229, 192, 0.4);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.6), var(--shadow-primary);
}

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

.card-score {
  position: absolute;
  top: 10px;
  right: 10px;
  padding: 3px 9px;
  font-size: 12px;
  font-weight: 700;
  font-family: var(--font-heading);
  color: #0A0A0C;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  border-radius: 999px;
  box-shadow: 0 0 16px rgba(0, 229, 192, 0.5);
}

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

.card-title {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 6px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

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

/* ============ Categories ============ */
.cat-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 14px;
}

.cat-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 18px;
  background: var(--glass);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 14px;
  transition: all .25s ease;
}
.cat-item:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-accent);
  transform: translateY(-3px);
  color: var(--accent);
}

.cat-count {
  font-size: 12px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.05);
  padding: 2px 9px;
  border-radius: 999px;
}

/* ============ Ranking ============ */
.rank-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 12px;
}

.rank-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 16px;
  background: var(--glass);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: all .25s ease;
}
.rank-item:hover {
  border-color: rgba(179, 107, 255, 0.4);
  box-shadow: var(--shadow-accent);
  transform: translateX(4px);
}

.rank-num {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-size: 15px;
  font-weight: 800;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.05);
  border-radius: 10px;
}
.rank-item:nth-child(1) .rank-num { color: #0A0A0C; background: linear-gradient(135deg, #FFD76B, #FF9A3C); box-shadow: 0 0 16px rgba(255, 200, 80, 0.5); }
.rank-item:nth-child(2) .rank-num { color: #0A0A0C; background: linear-gradient(135deg, #E0E0E8, #A0A0B0); }
.rank-item:nth-child(3) .rank-num { color: #0A0A0C; background: linear-gradient(135deg, #E8A87C, #C97B4A); }

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

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

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

.detail-head {
  display: flex;
  gap: 32px;
  padding: 28px;
  background: var(--glass);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5);
}

.detail-cover {
  flex-shrink: 0;
  width: 240px;
  aspect-ratio: 2 / 3;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.7), var(--shadow-accent);
}
.detail-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.detail-meta {
  flex: 1;
  min-width: 0;
}
.detail-meta h1 {
  font-size: 30px;
  margin-bottom: 8px;
}
.detail-meta .sub {
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 18px;
}
.detail-meta p {
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 6px;
}
.detail-meta p strong { color: var(--text); font-weight: 600; }

.detail-score {
  display: inline-flex;
  align-items: baseline;
  gap: 4px;
  margin-bottom: 18px;
  font-family: var(--font-heading);
  font-size: 34px;
  font-weight: 800;
  color: var(--primary);
  text-shadow: var(--shadow-primary);
}
.detail-score small {
  font-size: 14px;
  color: var(--muted);
  font-weight: 400;
}

.detail-body {
  margin-top: 28px;
  padding: 28px;
  background: var(--glass);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 15px;
  line-height: 1.9;
  color: var(--text);
}
.detail-body h2 {
  font-size: 20px;
  margin: 24px 0 12px;
  padding-left: 14px;
  border-left: 3px solid var(--primary);
}
.detail-body h2:first-child { margin-top: 0; }
.detail-body p { margin-bottom: 14px; color: #C8C8D2; }

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

.tag {
  display: inline-block;
  padding: 4px 12px;
  font-size: 12px;
  color: var(--primary);
  background: rgba(0, 229, 192, 0.08);
  border: 1px solid rgba(0, 229, 192, 0.25);
  border-radius: 999px;
  transition: all .2s ease;
}
.tag:hover {
  color: #0A0A0C;
  background: var(--primary);
  box-shadow: var(--shadow-primary);
}

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

.pg {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 14px;
  font-size: 14px;
  font-weight: 600;
  color: var(--muted);
  background: var(--glass);
  border: 1px solid var(--border);
  border-radius: 12px;
  transition: all .25s ease;
}
.pg:hover {
  color: var(--primary);
  border-color: var(--primary);
  box-shadow: var(--shadow-primary);
}
.pg.current {
  color: #0A0A0C;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  border-color: transparent;
  box-shadow: var(--shadow-primary);
}
.pg.disabled {
  opacity: .35;
  pointer-events: none;
  cursor: default;
}

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

.link-item {
  font-size: 13px;
  color: var(--muted);
  padding: 6px 14px;
  background: var(--glass);
  border: 1px solid var(--border);
  border-radius: 999px;
  transition: all .25s ease;
}
.link-item:hover {
  color: var(--accent);
  border-color: var(--accent);
  box-shadow: var(--shadow-accent);
}

/* ============ Crumbs ============ */
.crumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 20px 0;
  font-size: 13px;
  color: var(--muted);
}
.crumbs a { color: var(--muted); }
.crumbs a:hover { color: var(--primary); }
.crumbs span { color: var(--text); }

/* ============ Highlight ============ */
.hl {
  color: #0A0A0C;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  padding: 0 4px;
  border-radius: 4px;
  font-weight: 600;
}

/* ============ Footer ============ */
.footer {
  margin-top: 64px;
  padding: 40px 0 32px;
  border-top: 1px solid var(--border);
  background: linear-gradient(180deg, transparent, rgba(21, 21, 26, 0.6));
  font-size: 13px;
  color: var(--muted);
  text-align: center;
}
.footer p { margin-bottom: 8px; }
.footer a { color: var(--muted); }
.footer a:hover { color: var(--primary); }
.footer .footer-brand {
  font-family: var(--font-heading);
  font-size: 18px;
  font-weight: 800;
  margin-bottom: 12px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ============ Responsive ============ */
@media (max-width: 1024px) {
  .hero-info { padding: 28px; max-width: 75%; }
  .hero-info h2 { font-size: 26px; }
  .detail-cover { width: 200px; }
}

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

  .header .wrap {
    flex-wrap: wrap;
    height: auto;
    padding: 12px 16px;
    gap: 12px;
  }
  .logo { font-size: 19px; }
  .nav {
    order: 3;
    width: 100%;
    flex: none;
    gap: 2px;
    padding-bottom: 2px;
  }
  .nav a { padding: 7px 12px; font-size: 13px; }
  .search-box { margin-left: auto; }
  .search-box input { width: 150px; }
  .search-box input:focus { width: 170px; }

  .hero { margin: 20px 0 36px; }
  .hero-slide { aspect-ratio: 4 / 5; }
  .hero-slide::after {
    background: linear-gradient(0deg, rgba(10,10,12,.95) 0%, rgba(10,10,12,.4) 50%, transparent 80%);
  }
  .hero-info {
    padding: 20px;
    max-width: 100%;
  }
  .hero-info h2 { font-size: 22px; }
  .hero-info p { font-size: 13px; -webkit-line-clamp: 2; }

  .sec { margin-bottom: 40px; }
  .sec-title { font-size: 18px; }

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

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

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

  .detail-head {
    flex-direction: column;
    padding: 20px;
    gap: 20px;
  }
  .detail-cover {
    width: 160px;
    align-self: center;
  }
  .detail-meta h1 { font-size: 22px; }
  .detail-score { font-size: 28px; }
  .detail-body { padding: 20px; font-size: 14px; }

  .pg { min-width: 36px; height: 36px; padding: 0 10px; font-size: 13px; }

  .footer { margin-top: 40px; padding: 28px 0 24px; }
}