/* ====== CSS Variables ====== */
:root {
  /* 中性炭灰为主色，灰紫只表示交互；金色仅用于冠军 */
  --bg: #141518;
  --bg-secondary: #191b1f;
  --bg-card: #1d1f23;
  --bg-card-hover: #23262b;
  --border: #34363c;
  --border-active: #555962;
  --text: #e8e8e6;
  --text-secondary: #b4b6bc;
  --text-muted: #979aa2;
  --gold: #c5a66b;
  --gold-dim: #ad925f;
  --gold-bg: rgba(197, 166, 107, 0.12);
  --red: #bd8583;
  --red-bg: rgba(189, 133, 131, 0.12);
  --green: #88b49a;
  --green-bg: rgba(136, 180, 154, 0.12);
  --primary: #b8aecb;
  --primary-hover: #cbc1d8;
  --radius: 12px;
  --radius-lg: 16px;
  --shadow: 0 16px 48px rgba(0, 0, 0, 0.24);
  --transition: 0.18s ease;
}

/* ====== Reset & Base ====== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Noto Sans SC', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ====== Navbar ====== */
.navbar {
  position: sticky; top: 0; z-index: 100;
  background: rgba(8, 8, 15, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
}

.nav-inner {
  max-width: 1100px; margin: 0 auto;
  padding: 0 20px; height: 60px;
  display: flex; align-items: center; justify-content: space-between;
}

.nav-logo { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 1.05rem; }
.nav-logo:hover { text-decoration: none; }
.logo-icon { font-size: 1.4rem; }
.logo-text { background: none; -webkit-background-clip: text; -webkit-text-fill-color: transparent; }

.nav-actions { display: flex; gap: 8px; align-items: center; }
.nav-user { font-size: 0.88rem; color: var(--text); font-weight: 500; }
.nav-votes { font-size: 0.82rem; color: var(--gold); background: var(--gold-bg); padding: 3px 10px; border-radius: 20px; }

/* ====== Buttons ====== */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  font-family: inherit; font-size: 0.9rem; font-weight: 500;
  padding: 10px 20px; border-radius: 8px; border: none; cursor: pointer;
  transition: all var(--transition); position: relative; overflow: hidden;
  text-decoration: none;
}
.btn:hover { text-decoration: none; }

.btn:active { transform: scale(0.97); }

.btn-primary {
  background: var(--primary);
  color: #1a1a0a;
}
.btn-primary:hover { background: var(--primary-hover); box-shadow: 0 4px 20px rgba(192, 144, 48, 0.3); }

.btn-outline {
  background: transparent; color: var(--text-secondary);
  border: 1px solid var(--border);
}
.btn-outline:hover { border-color: var(--border-active); color: var(--text); background: rgba(255,255,255,0.03); }

.btn-sm { padding: 6px 14px; font-size: 0.82rem; border-radius: 6px; }
.btn-lg { padding: 14px 28px; font-size: 1rem; border-radius: 10px; }
.btn-full { width: 100%; }

.btn-vote {
  width: 36px; height: 36px; padding: 0; border-radius: 8px;
  border: 1px solid var(--border); background: transparent;
  color: var(--text-secondary); font-size: 1.1rem; cursor: pointer;
  transition: all var(--transition);
}
.btn-vote:hover { border-color: var(--border-active); background: rgba(255,255,255,0.05); }
.btn-vote.active-up { background: var(--green-bg); border-color: var(--green); color: var(--green); }
.btn-vote.active-down { background: var(--red-bg); border-color: var(--red); color: var(--red); }

/* ====== Hero ====== */
.hero {
  position: relative; padding: 80px 20px 60px; text-align: center; overflow: hidden;
}

.hero-bg {
  position: absolute; inset: 0;
  background: none;
  pointer-events: none;
}

.hero-content { position: relative; z-index: 1; max-width: 700px; margin: 0 auto; }

.hero-title { margin-bottom: 16px; }

.title-line-1 {
  display: block; font-size: 1.2rem; font-weight: 500;
  color: var(--gold); letter-spacing: 0.3em; text-transform: uppercase; margin-bottom: 4px;
}
.title-line-2 {
  display: block; font-size: 3.2rem; font-weight: 900;
  background: none;
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  letter-spacing: 0.05em;
}

.hero-subtitle { color: var(--text-secondary); font-size: 1.05rem; margin-bottom: 40px; }

.hero-stats { display: flex; align-items: center; justify-content: center; gap: 32px; }

.stat-item { text-align: center; }
.stat-num { display: block; font-size: 2rem; font-weight: 900; color: var(--gold); font-variant-numeric: tabular-nums; }
.stat-label { font-size: 0.85rem; color: var(--text-secondary); }
.stat-divider { width: 1px; height: 40px; background: var(--border); }

/* ====== Main Content ====== */
.main { padding: 0 20px 60px; }
.container { max-width: 800px; margin: 0 auto; }

/* ====== Tabs ====== */
.tabs { display: flex; gap: 4px; margin-bottom: 24px; background: var(--bg-secondary); padding: 4px; border-radius: 10px; border: 1px solid var(--border); }

.tab {
  flex: 1; padding: 10px; border: none; border-radius: 7px;
  background: transparent; color: var(--text-secondary); cursor: pointer;
  font-family: inherit; font-size: 0.9rem; font-weight: 500;
  transition: all var(--transition);
}
.tab:hover { color: var(--text); }
.tab.active { background: rgba(255,255,255,0.06); color: var(--text); }

.tab-content { display: none; }
.tab-content.active { display: block; animation: fadeIn 0.3s ease; }

/* ====== Search Bar ====== */
.search-bar { margin-bottom: 16px; }
.search-input {
  width: 100%; padding: 10px 16px; border-radius: 8px;
  border: 1px solid var(--border); background: rgba(0,0,0,0.2);
  color: var(--text); font-family: inherit; font-size: 0.9rem;
  outline: none; transition: border-color var(--transition);
}
.search-input:focus { border-color: var(--gold-dim); }
.search-input::placeholder { color: var(--text-muted); }

/* ====== Sort Bar ====== */
.sort-bar { display: flex; align-items: center; gap: 8px; margin-bottom: 24px; }
.sort-label { color: var(--text-secondary); font-size: 0.85rem; }
.sort-btn {
  padding: 5px 14px; border-radius: 20px; border: 1px solid var(--border);
  background: transparent; color: var(--text-secondary); cursor: pointer;
  font-family: inherit; font-size: 0.82rem; transition: all var(--transition);
}
.sort-btn:hover { border-color: var(--border-active); color: var(--text); }
.sort-btn.active { background: var(--gold-bg); border-color: var(--gold-dim); color: var(--gold); }

/* ====== 排行榜：清晰的分值层次，不使用装饰性渐变 ====== */
.podium {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  align-items: stretch;
  margin-bottom: 16px;
}
.podium:empty { display: none; }
.podium-card,
.entry-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  min-width: 0;
  transition: background var(--transition), border-color var(--transition);
}
.podium-card:hover,
.entry-card:hover { background: var(--bg-card-hover); border-color: var(--border-active); }
.podium-card {
  display: flex;
  flex-direction: column;
  padding: 16px;
  gap: 14px;
}
.podium-card.rank-1 { border-color: rgba(197, 166, 107, 0.55); order: 2; }
.podium-card.rank-2 { order: 1; }
.podium-card.rank-3 { order: 3; }
.podium-main,
.entry-card-main {
  min-width: 0;
  cursor: pointer;
}
.podium-main { display: grid; grid-template-columns: 42px minmax(0,1fr); column-gap: 10px; align-items: start; }
.podium-rank {
  grid-column: 1;
  grid-row: 1;
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 11px;
  color: var(--text-secondary);
  border: 1px solid var(--border);
  background: var(--bg-secondary);
  font-size: 1rem;
  font-weight: 800;
}
.rank-1 .podium-rank { color: var(--gold); border-color: rgba(197,166,107,.4); background: var(--gold-bg); font-size: 1.5rem; }
.podium-info { grid-column: 2; grid-row: 1; min-width: 0; }
.podium-label { color: var(--text-muted); font-size: 0.72rem; margin-bottom: 2px; }
.rank-1 .podium-label { color: var(--gold); }
.podium-name { color: var(--text); font-size: 1rem; font-weight: 750; overflow-wrap: anywhere; line-height: 1.35; }
.podium-desc { font-size: 0.83rem; color: var(--text-secondary); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; margin-top: 4px; }
.podium-score { grid-column: 1 / -1; grid-row: 2; margin-top: 10px; }
.podium-bottom { display: flex; flex-direction: column; gap: 10px; margin-top: auto; }
.podium-votes, .entry-votes { display: flex; gap: 8px; }
.podium-votes .btn-vote { flex: 1; }
.vote-counts { color: var(--text-secondary); font-size: 0.78rem; font-variant-numeric: tabular-nums; }
.score-bar-wrap { display: inline-flex; gap: 7px; align-items: baseline; min-width: 0; }
.score-bar-num { font-variant-numeric: tabular-nums; font-size: 1.55rem; font-weight: 750; color: var(--text); line-height: 1; letter-spacing: -0.035em; }
.score-bar-caption { color: var(--text-muted); font-size: .73rem; }
.rank-1 .score-bar-num { font-size: 1.8rem; color: var(--gold); }
.detail-score-bar .score-bar-num { font-size: 2.15rem; }
.btn-vote {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  min-width: 70px;
  min-height: 44px;
  padding: 8px 12px;
  border-radius: 9px;
  font-family: inherit;
  font-size: .86rem;
  font-weight: 600;
  cursor: pointer;
  border: 1px solid var(--border);
  background: var(--bg-secondary);
  color: var(--text-secondary);
  transition: background var(--transition), border-color var(--transition), color var(--transition);
}
.btn-vote:hover { background: var(--bg-card-hover); border-color: var(--border-active); color: var(--text); }
.btn-vote.active-up { background: var(--green-bg); border-color: var(--green); color: #bbdfc5; }
.btn-vote.active-down { background: var(--red-bg); border-color: var(--red); color: #e0a9a7; }
.btn-vote:disabled { opacity: .55; cursor: wait; }
.leaderboard-list { display: flex; flex-direction: column; gap: 10px; }
.entry-card { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 12px; padding: 16px 18px; }
.entry-card-main { display: flex; align-items: center; gap: 12px; }
.entry-rank-num {
  display: grid; place-items: center; flex-shrink: 0;
  min-width: 38px; height: 38px; padding: 0 5px;
  background: var(--bg-secondary); border: 1px solid var(--border);
  border-radius: 10px; font-weight: 700; font-size: .87rem; color: var(--text-secondary);
}
.entry-info { min-width: 0; flex: 1; }
.entry-name { font-size: .98rem; font-weight: 700; color: var(--text); overflow-wrap: anywhere; }
.entry-desc { color: var(--text-secondary); font-size: .84rem; line-height: 1.5; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; }
.entry-meta { display: flex; flex-wrap: wrap; gap: 4px 10px; color: var(--text-muted); font-size: .76rem; margin-top: 4px; }
.entry-metrics { display: flex; align-items: center; justify-content: flex-end; white-space: nowrap; }
.entry-footer { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: space-between; border-top: 1px solid var(--border); padding-top: 10px; }
.entry-footer .vote-counts { margin-right: auto; }
.entry-votes .btn-vote { min-width: 80px; }
.entry-votes { flex-shrink: 0; }

/* ====== Content Rules Box ====== */
.rules-box {
  margin-top: 20px; border: 1px solid var(--border);
  border-radius: var(--radius); overflow: hidden;
  background: rgba(255,255,255,0.015);
}
.rules-box summary {
  padding: 14px 20px; font-size: 0.9rem; font-weight: 600;
  color: var(--text-secondary); cursor: pointer;
  user-select: none; transition: color var(--transition);
}
.rules-box summary:hover { color: var(--text); }
.rules-content { padding: 0 20px 18px; }
.rules-content h3 { font-size: 0.88rem; font-weight: 600; margin: 16px 0 6px; color: var(--text); }
.rules-content h3:first-child { margin-top: 4px; }
.rules-content ul { list-style: none; padding: 0; }
.rules-content li {
  font-size: 0.82rem; color: var(--text-secondary);
  padding: 3px 0; padding-left: 16px; position: relative;
}
.rules-content li::before {
  content: '·'; position: absolute; left: 4px;
  color: var(--text-muted); font-weight: 700;
}
.rules-content strong { color: var(--text); }

/* ====== Empty State ====== */
.empty-state { text-align: center; padding: 60px 20px; }
.empty-icon { font-size: 3rem; margin-bottom: 16px; }
.empty-state h3 { font-size: 1.2rem; margin-bottom: 8px; }
.empty-state p { color: var(--text-secondary); }

/* ====== Load More ====== */
.load-more { text-align: center; padding: 24px 0; }
.load-more.hidden { display: none; }

/* ====== Submit Card ====== */
.submit-card, .submit-login-hint {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 32px;
}
.submit-login-hint { text-align: center; display: none; }
.submit-login-hint .hint-icon { font-size: 3rem; margin-bottom: 16px; }
.submit-login-hint h3 { margin-bottom: 8px; }
.submit-login-hint p { color: var(--text-secondary); margin-bottom: 20px; }
.hint-actions { display: flex; gap: 10px; justify-content: center; }

.section-title { font-size: 1.3rem; font-weight: 700; margin-bottom: 24px; }

.submit-form { display: flex; flex-direction: column; gap: 18px; }

.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-group label { font-size: 0.88rem; font-weight: 500; color: var(--text-secondary); }
.required { color: var(--red); }

.form-group input,
.form-group textarea,
.form-group select {
  font-family: inherit; font-size: 0.95rem; padding: 12px 14px;
  border-radius: 8px; border: 1px solid var(--border);
  background: rgba(0,0,0,0.2); color: var(--text);
  transition: border-color var(--transition); outline: none; resize: vertical;
}
.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus { border-color: var(--gold-dim); }

.form-group select { cursor: pointer; }
.form-group select option { background: var(--bg-secondary); color: var(--text); }

/* ====== Modal ====== */
.modal-overlay {
  position: fixed; inset: 0; z-index: 200;
  display: flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,0.6); backdrop-filter: blur(4px);
  visibility: hidden; opacity: 0; pointer-events: none;
  transition: visibility 0.3s, opacity 0.3s;
}
.modal-overlay.active {
  visibility: visible; opacity: 1; pointer-events: auto;
}

.modal {
  background: var(--bg-secondary); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 32px; width: 100%; max-width: 400px;
  position: relative; box-shadow: var(--shadow);
  transform: scale(0.92) translateY(24px);
  opacity: 0;
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.25s;
}
.modal-overlay.active .modal {
  transform: scale(1) translateY(0); opacity: 1;
}

.modal-close {
  position: absolute; top: 12px; right: 16px;
  background: none; border: none; color: var(--text-secondary);
  font-size: 1.5rem; cursor: pointer; padding: 4px 8px; line-height: 1;
  transition: color var(--transition), transform var(--transition);
}
.modal-close:hover { color: var(--text); transform: rotate(90deg); }

.modal-title { font-size: 1.3rem; font-weight: 700; margin-bottom: 24px; text-align: center; }

.modal form { display: flex; flex-direction: column; gap: 16px; }

.modal-switch { text-align: center; font-size: 0.88rem; color: var(--text-secondary); margin-top: 16px; }

/* ====== Fullscreen Overlay (Login/Register) ====== */
.modal-overlay-fullscreen {
  align-items: stretch;
  background: var(--bg);
  backdrop-filter: none;
  transition: visibility 0.4s, opacity 0.4s;
}
.modal-overlay-fullscreen .modal {
  max-width: 100%; flex: 1; border-radius: 0; border: none;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 40px 24px;
  transform: translateY(60px); opacity: 0;
  transition: transform 0.45s cubic-bezier(0.32, 0.72, 0, 1), opacity 0.35s;
  box-shadow: none; background: transparent;
}
.modal-overlay-fullscreen.active .modal {
  transform: translateY(0); opacity: 1;
}

.fullscreen-modal-inner {
  width: 100%; max-width: 420px;
}

.fullscreen-modal-header {
  text-align: center; margin-bottom: 40px;
}
.fullscreen-modal-header .logo-icon { font-size: 3rem; display: block; margin-bottom: 8px; }
.fullscreen-modal-header .logo-text {
  font-size: 1.4rem; font-weight: 900;
  background: none;
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}

.modal-overlay-fullscreen .modal-close {
  top: 20px; right: 24px; font-size: 1.8rem;
  width: 44px; height: 44px; display: flex; align-items: center; justify-content: center;
  border-radius: 50%; background: rgba(255,255,255,0.04);
}
.modal-overlay-fullscreen .modal-close:hover {
  background: rgba(255,255,255,0.08); transform: rotate(90deg);
}

/* ====== Standalone Auth Pages ====== */
.auth-page {
  min-height: 100vh; display: flex; align-items: center; justify-content: center;
  background: var(--bg);
  background-image: none;
}

.auth-container {
  width: 100%; max-width: 440px; padding: 24px;
}

.auth-card {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 40px 32px;
  animation: fadeIn 0.4s ease, slideUp 0.5s ease;
}

.auth-logo {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  margin-bottom: 32px; text-decoration: none;
}
.auth-logo:hover { text-decoration: none; }
.auth-logo-icon { font-size: 2.5rem; }
.auth-logo-text {
  font-size: 1.3rem; font-weight: 900;
  background: none;
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}

.auth-title { font-size: 1.4rem; font-weight: 700; text-align: center; margin-bottom: 28px; }

.auth-form { display: flex; flex-direction: column; gap: 16px; }

.auth-error {
  background: var(--red-bg); border: 1px solid var(--red);
  color: var(--red); padding: 10px 14px; border-radius: 8px;
  font-size: 0.88rem; animation: fadeIn 0.2s ease;
}

.auth-switch { text-align: center; font-size: 0.9rem; color: var(--text-secondary); margin-top: 20px; }
.auth-back { text-align: center; margin-top: 16px; }
.auth-back a { font-size: 0.85rem; color: var(--text-muted); }
.auth-back a:hover { color: var(--text-secondary); }

/* ====== Account Tab ====== */
.account-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 20px;
}

.account-card {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 24px;
}

.account-card-full {
  grid-column: 1 / -1;
}

.account-card-title {
  font-size: 1rem; font-weight: 700; margin-bottom: 16px;
  display: flex; align-items: center; gap: 8px;
}

.account-info-item {
  display: flex; justify-content: space-between; align-items: center;
  padding: 10px 0; border-bottom: 1px solid var(--border);
}
.account-info-item:last-child { border-bottom: none; }
.account-info-label { font-size: 0.88rem; color: var(--text-secondary); }
.account-info-value { font-size: 0.95rem; font-weight: 600; }
.account-info-value.votes { color: var(--gold); font-size: 1.2rem; }
.account-info-value.role-badge {
  font-size: 0.78rem; padding: 2px 10px; border-radius: 20px;
}
.account-info-value.role-badge.owner { background: rgba(240,192,96,0.15); color: #f0d080; }
.account-info-value.role-badge.admin { background: var(--gold-bg); color: var(--gold); }
.account-info-value.role-badge.user { background: rgba(255,255,255,0.05); color: var(--text-secondary); }

@media (max-width: 640px) {
  .account-grid { grid-template-columns: 1fr; }
  .auth-card { padding: 28px 20px; }
}

/* ====== Toast ====== */
.toast-container {
  position: fixed; top: 72px; right: 20px; z-index: 300;
  display: flex; flex-direction: column; gap: 8px;
}

.toast {
  padding: 12px 20px; border-radius: 8px; font-size: 0.9rem;
  font-weight: 500; box-shadow: var(--shadow);
  animation: slideInRight 0.3s ease;
  max-width: 360px;
}
.toast.success { background: #0d2818; border: 1px solid #1a5c30; color: #50c878; }
.toast.error { background: #280d0d; border: 1px solid #5c1a1a; color: #e05050; }
.toast.info { background: #0d1828; border: 1px solid #1a305c; color: #5090e0; }

/* ====== Footer ====== */
.footer { text-align: center; padding: 40px 20px; border-top: 1px solid var(--border); color: var(--text-muted); font-size: 0.85rem; }
.footer-sub { font-size: 0.78rem; margin-top: 4px; }

/* ====== Animations ====== */
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes slideInRight { from { opacity: 0; transform: translateX(40px); } to { opacity: 1; transform: translateX(0); } }
@keyframes slideUp { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: translateY(0); } }

/* ====== Responsive ====== */
@media (max-width: 640px) {
  .title-line-2 { font-size: 2.2rem; }
  .hero { padding: 48px 16px 36px; }
  .hero-stats { gap: 20px; }
  .stat-num { font-size: 1.5rem; }
  .entry-card { padding: 12px 14px; gap: 10px; }
  .submit-card, .submit-login-hint { padding: 20px; }
  .modal { margin: 0 16px; padding: 24px; }
  .modal-overlay-fullscreen .modal { margin: 0; padding: 24px; }
  .fullscreen-modal-inner { max-width: 100%; }
  .fullscreen-modal-header { margin-bottom: 28px; }
  .fullscreen-modal-header .logo-icon { font-size: 2.2rem; }
  .logo-text { display: none; }
  .fullscreen-modal-header .logo-text { display: block; font-size: 1.1rem; }
}

/* ====== Detail Modal ====== */
.modal-detail { max-width: 540px; }

.detail-header { text-align: center; margin-bottom: 20px; }
.detail-name { font-size: 1.5rem; font-weight: 900; margin-bottom: 4px; }
.detail-category { font-size: 0.82rem; color: var(--gold); background: var(--gold-bg); padding: 2px 12px; border-radius: 20px; display: inline-block; }
.detail-score-big { font-size: 2.5rem; font-weight: 900; color: var(--gold); text-align: center; margin: 16px 0 8px; }
.detail-vote-stats { display: flex; justify-content: center; gap: 24px; font-size: 0.9rem; margin-bottom: 16px; }
.detail-desc { font-size: 0.95rem; line-height: 1.7; color: var(--text-secondary); margin-bottom: 20px; white-space: pre-wrap; }
.detail-meta { font-size: 0.8rem; color: var(--text-muted); text-align: center; margin-bottom: 16px; }
.detail-actions { display: flex; justify-content: center; gap: 8px; margin-top: 8px; }
.detail-votes { display: flex; align-items: center; justify-content: center; gap: 16px; }
.detail-votes .btn-vote { width: 48px; height: 48px; font-size: 1.3rem; border-radius: 12px; }

/* ====== Edit Entry Modal ====== */
.modal-edit-entry { max-width: 560px; }

/* ====== Admin Panel ====== */
.admin-panel { background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 28px; }
.admin-tabs { display: flex; gap: 4px; margin: 20px 0; background: var(--bg-secondary); padding: 4px; border-radius: 8px; border: 1px solid var(--border); }
.admin-tab { flex: 1; padding: 8px; border: none; border-radius: 6px; background: transparent; color: var(--text-secondary); cursor: pointer; font-family: inherit; font-size: 0.85rem; font-weight: 500; transition: all var(--transition); }
.admin-tab:hover { color: var(--text); }
.admin-tab.active { background: rgba(255,255,255,0.06); color: var(--text); }
.admin-content { display: none; }
.admin-content.active { display: block; }
.admin-table-wrap { overflow-x: auto; }
.admin-table { width: 100%; border-collapse: collapse; font-size: 0.88rem; }
.admin-table th, .admin-table td { padding: 10px 12px; text-align: left; border-bottom: 1px solid var(--border); }
.admin-table th { color: var(--text-secondary); font-weight: 500; font-size: 0.8rem; text-transform: uppercase; }
.admin-table td { color: var(--text); }
.admin-table .role-badge { font-size: 0.78rem; padding: 2px 10px; border-radius: 20px; font-weight: 500; }
.admin-table .role-badge.admin { background: var(--gold-bg); color: var(--gold); }
.admin-table .role-badge.owner { background: rgba(240,192,96,0.15); color: #f0d080; }
.admin-table .role-badge.unauthorized { background: var(--red-bg); color: var(--red); }
.admin-table .role-badge.user { background: rgba(255,255,255,0.05); color: var(--text-secondary); }
.admin-table select, .admin-table input { font-family: inherit; font-size: 0.8rem; padding: 4px 8px; border-radius: 4px; border: 1px solid var(--border); background: var(--bg); color: var(--text); }
.admin-table select { cursor: pointer; }
.admin-inline-form { display: flex; gap: 6px; align-items: center; }

/* ====== Ban Buttons ====== */
.ban-btn-group { display: inline-flex; flex-wrap: wrap; gap: 2px; }
.ban-btn-group .btn-sm { padding: 3px 7px; font-size: 0.72rem; border-radius: 4px; }
.ban-btn-inline { display: none; flex-wrap: wrap; gap: 2px; }

/* ====== Batch Bar ====== */
.batch-bar {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  padding: 10px 14px; background: var(--gold-bg); border: 1px solid var(--gold-dim);
  border-radius: 8px; margin-bottom: 12px; animation: fadeIn 0.2s ease;
}
.batch-count { font-size: 0.85rem; color: var(--gold); font-weight: 600; margin-right: 8px; }

/* ====== Admin Search ====== */
.admin-search-bar { margin-bottom: 16px; }

/* ====== Pagination ====== */
.pagination-bar {
  display: flex; align-items: center; justify-content: center; gap: 12px;
  padding: 16px 0 4px;
}
.pagination-bar .btn-sm { padding: 6px 14px; }
.pagination-bar .btn-sm:disabled { opacity: 0.4; pointer-events: none; }
.page-info { font-size: 0.85rem; color: var(--text-secondary); }

/* 分页切换动画 */
.admin-table-wrap tbody { transition: opacity 0.15s ease; }
.admin-table-wrap tbody.switching { opacity: 0.4; }

/* ====== Footer Disclaimer ====== */
.footer-disclaimer { font-size: 0.75rem; margin-top: 8px; color: var(--text-muted); opacity: 0.7; }


/* 加载动画喵～ */
.spinner {
  width: 36px;
  height: 36px;
  margin: 0 auto;
  border: 3px solid var(--border);
  border-top-color: var(--gold);
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}
@keyframes spin {
  to { transform: rotate(360deg); }
}

/* 投票按钮加载态喵～ */
.btn-vote.loading {
  opacity: 0.5;
  pointer-events: none;
  animation: pulse 0.8s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 0.5; }
  50% { opacity: 0.8; }
}

/* ====== 非 AI 风格统一主题：中性底色与少量荣誉金 ====== */
.nav-inner { height: 56px; }
.navbar { background: rgba(20, 21, 24, .94); }
.nav-votes { color: var(--text); background: var(--bg-secondary); border: 1px solid var(--border); }
.hero { padding: 34px 20px 26px; }
.hero-bg { display: none; }
.hero-title { margin-bottom: 6px; line-height: 1.1; }
.title-line-1 { font-size: .84rem; letter-spacing: .16em; color: var(--text-secondary); margin-bottom: 4px; }
.title-line-2 { font-size: clamp(2rem, 4vw, 2.6rem); color: var(--text); letter-spacing: 0; background: none; -webkit-text-fill-color: currentColor; }
.hero-subtitle { font-size: .92rem; margin: 6px 0 14px; }
.hero-stats { gap: 22px; }
.stat-num { color: var(--text); font-size: 1.45rem; }
.stat-label { font-size: .78rem; }
.tabs { border-color: var(--border); }
.tab.active { background: #303038; color: var(--text); }
.sort-btn.active { color: var(--text); border-color: #696274; background: rgba(163,154,185,.12); }
.btn-primary { background: var(--primary); color: #15151a; font-weight: 650; }
.btn-primary:hover { background: var(--primary-hover); box-shadow: none; }
.logo-text { color: var(--text); background: none; -webkit-text-fill-color: currentColor; }
.fullscreen-modal-header .logo-text { background: none; color: var(--text); -webkit-text-fill-color: currentColor; }
.auth-page { background-image: none; }
.search-bar { display: flex; gap: 8px; }
.search-input { min-height: 44px; background: var(--bg-secondary); }
.search-input:focus { border-color: var(--primary); }
.form-group input:focus, .form-group textarea:focus, .form-group select:focus { border-color: var(--primary); }
.search-bar #clearSearch { flex-shrink: 0; }
.modal { background: var(--bg-card); }
.modal-overlay { background: rgba(0,0,0,.68); }
.vote-rule { color: var(--text-secondary); font-size: .85rem; margin: 12px 0; }
:focus-visible { outline: 2px solid var(--primary); outline-offset: 3px; }
input, select, textarea { font-size: max(16px, 1em); }
@media (max-width: 640px) {
  .nav-inner { padding-inline: 12px; }
  .hero { padding: 22px 16px 20px; }
  .hero-stats { gap: 15px; }
  .stat-num { font-size: 1.25rem; }
  .podium { display: flex; flex-direction: column; gap: 10px; }
  .podium-card { order: initial !important; width: 100%; padding: 13px 14px; }
  .podium-main { display: grid; grid-template-columns: 44px minmax(0,1fr) auto; gap: 9px; align-items: center; }
  .podium-rank { grid-column: 1; grid-row: 1; }
  .podium-info { grid-column: 2; grid-row: 1; }
  .podium-score { grid-column: 3; grid-row: 1; margin: 0; text-align: right; }
  .podium-score .score-bar-wrap { display: flex; flex-direction: column; gap: 2px; align-items: flex-end; }
  .podium-card.rank-1 { padding: 16px; }
  .rank-1 .podium-score .score-bar-num { font-size: 1.75rem; }
  .podium-desc { -webkit-line-clamp: 1; }
  .podium-bottom { flex-direction: row; gap: 8px; justify-content: space-between; align-items: center; flex-wrap: wrap; }
  .podium-votes { flex: 1 0 100%; }
  .podium-votes .btn-vote { flex: 1; }
  .entry-card { display: grid; grid-template-columns: minmax(0,1fr) auto; padding: 13px; gap: 10px; }
  .entry-card-main { gap: 8px; }
  .entry-metrics .score-bar-wrap { flex-direction: column; align-items: flex-end; gap: 2px; }
  .entry-footer { display: flex; gap: 8px; }
  .entry-votes { width: 100%; }
  .entry-votes .btn-vote { flex: 1; }
  .modal-overlay { padding: 0; align-items: flex-end; }
  .modal { max-height: 90dvh; overflow-y: auto; border-radius: 18px 18px 0 0; padding-bottom: max(20px, env(safe-area-inset-bottom)); }
  .tabs { overflow-x: auto; }
}
@media (max-width: 350px) {
  .entry-card { grid-template-columns: 1fr; }
  .entry-metrics { grid-column: 1; grid-row: 2; justify-content: flex-start; }
  .entry-metrics .score-bar-wrap { flex-direction: row; align-items: baseline; }
  .entry-footer { grid-row: 3; }
  .podium-info { overflow: hidden; }
  .podium-name { font-size: .92rem; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important; animation-iteration-count: 1 !important;
    transition-duration: .01ms !important; scroll-behavior: auto !important;
  }
}
