.toplist-page {
  --gradient-primary: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  --gradient-secondary: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
  --glass-bg: rgba(255, 255, 255, 0.12);
  --glass-border: rgba(255, 255, 255, 0.22);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, 'Noto Sans', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
}

.toplist-page .toplist-hero__title {
  font-family: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  letter-spacing: 0.2px;
}

.toplist-page .toplist-hero {
  background: linear-gradient(135deg, rgba(102, 126, 234, 0.18) 0%, rgba(118, 75, 162, 0.14) 55%, transparent 100%);
}

.toplist-page details.toplist-day {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  transition: transform 0.28s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.28s cubic-bezier(0.4, 0, 0.2, 1);
}

@supports ((-webkit-backdrop-filter: blur(10px)) or (backdrop-filter: blur(10px))) {
  .toplist-page details.toplist-day {
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
  }
}

.toplist-page details.toplist-day:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.toplist-page details.toplist-day[open] .toplist-day__body {
  animation: toplist-slide-in 0.45s ease-out;
}

@keyframes toplist-slide-in {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.toplist-page .toplist-entry__content ol {
  list-style: none;
  padding-left: 0;
  margin: 0.25rem 0 0 0;
  counter-reset: rank-counter;
}

.toplist-page .toplist-entry__content li {
  counter-increment: rank-counter;
  padding: 0.55rem 0.75rem 0.55rem 3.35rem;
  position: relative;
  border-radius: 12px;
  transition: background-color 0.18s ease, transform 0.18s ease;
}

.toplist-page .toplist-entry__content li::before {
  content: counter(rank-counter);
  position: absolute;
  left: 0.85rem;
  top: 0.58rem;
  width: 2.1rem;
  height: 1.65rem;
  background: rgba(148, 163, 184, 0.18);
  border: 1px solid rgba(148, 163, 184, 0.28);
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--text-color);
  box-shadow: none;
}

.toplist-page .toplist-entry__content li:hover {
  background: rgba(255, 255, 255, 0.06);
}

.toplist-page .toplist-entry__content li:nth-child(1)::before {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.38), rgba(251, 191, 36, 0.22));
  border-color: rgba(245, 158, 11, 0.45);
  color: #b45309;
}

.toplist-page .toplist-entry__content li:nth-child(2)::before {
  background: linear-gradient(135deg, rgba(148, 163, 184, 0.35), rgba(226, 232, 240, 0.18));
  border-color: rgba(148, 163, 184, 0.45);
  color: #475569;
}

.toplist-page .toplist-entry__content li:nth-child(3)::before {
  background: linear-gradient(135deg, rgba(234, 88, 12, 0.32), rgba(251, 146, 60, 0.18));
  border-color: rgba(234, 88, 12, 0.45);
  color: #9a3412;
}

.toplist-page .toplist-entry__content li:nth-child(-n + 3) {
  background: rgba(102, 126, 234, 0.08);
}

html[data-user-color-scheme='dark'] .toplist-page {
  --glass-bg: rgba(10, 18, 28, 0.38);
  --glass-border: rgba(255, 255, 255, 0.12);
}

html[data-user-color-scheme='dark'] .toplist-page .toplist-entry__content li:hover {
  background: rgba(255, 255, 255, 0.04);
}

html[data-user-color-scheme='dark'] .toplist-page .toplist-entry__content li::before {
  background: rgba(148, 163, 184, 0.16);
  border-color: rgba(148, 163, 184, 0.22);
  color: rgba(226, 232, 240, 0.92);
}

html[data-user-color-scheme='dark'] .toplist-page .toplist-entry__content li:nth-child(1)::before {
  color: rgba(251, 191, 36, 0.95);
}

html[data-user-color-scheme='dark'] .toplist-page .toplist-entry__content li:nth-child(2)::before {
  color: rgba(226, 232, 240, 0.9);
}

html[data-user-color-scheme='dark'] .toplist-page .toplist-entry__content li:nth-child(3)::before {
  color: rgba(251, 146, 60, 0.92);
}

html[data-user-color-scheme='dark'] .toplist-page .toplist-entry__content li:nth-child(-n + 3) {
  background: rgba(99, 102, 241, 0.12);
}

.toplist-page .toplist-entry__content li.toplist-clicked {
  background: rgba(102, 126, 234, 0.12);
  transform: translateY(-1px);
}

@keyframes toplist-pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.06); }
  100% { transform: scale(1); }
}

.toplist-page .toplist-entry__content li.toplist-clicked::before {
  animation: toplist-pulse 0.3s ease;
}

@media (prefers-reduced-motion: reduce) {
  .toplist-page details.toplist-day,
  .toplist-page .toplist-entry__content li,
  .toplist-page details.toplist-day[open] .toplist-day__body {
    transition: none;
    animation: none;
  }
}

@media (max-width: 767px) {
  .toplist-page details.toplist-day:hover {
    transform: none;
    box-shadow: none;
  }
}
