:root {
  --bg: #f2f2f7;
  --surface: rgba(255, 255, 255, 0.72);
  --surface-strong: rgba(255, 255, 255, 0.82);
  --surface-hover: rgba(255, 255, 255, 0.92);
  --border: rgba(0, 0, 0, 0.08);
  --border-hover: rgba(0, 0, 0, 0.16);
  --text-primary: #1d1d1f;
  --text-secondary: #6e6e73;
  --text-tertiary: #aeaeb2;
  --accent: #0071e3;
  --accent-soft: rgba(0, 113, 227, 0.1);
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 24px 64px rgba(0, 0, 0, 0.13);
  --radius-card: 20px;
  --radius-pill: 999px;
  --blur: blur(20px) saturate(180%);
  --font-ui: -apple-system, BlinkMacSystemFont, "SF Pro Display", "PingFang SC", "Helvetica Neue", sans-serif;
  --font-reading: "LXGW WenKai", "PingFang SC", "Microsoft YaHei", sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #000;
    --surface: rgba(28, 28, 30, 0.8);
    --surface-strong: rgba(38, 38, 42, 0.9);
    --surface-hover: rgba(44, 44, 46, 0.94);
    --border: rgba(255, 255, 255, 0.08);
    --border-hover: rgba(255, 255, 255, 0.18);
    --text-primary: #f5f5f7;
    --text-secondary: #98989d;
    --text-tertiary: #636366;
    --accent: #2997ff;
    --accent-soft: rgba(41, 151, 255, 0.12);
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.35);
    --shadow-lg: 0 24px 64px rgba(0, 0, 0, 0.55);
  }
}

@font-face {
  font-family: "LXGW WenKai";
  src: url("../assets/fonts/lxgw/LXGWWenKai-Medium.woff2") format("woff2");
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "LXGW WenKai";
  src: url("../assets/fonts/lxgw/LXGWWenKai-Medium.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "LXGW WenKai";
  src: url("../assets/fonts/lxgw/LXGWWenKai-Medium.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  font-family: var(--font-ui);
  -webkit-font-smoothing: antialiased;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text-primary);
  background: var(--bg);
  background-image:
    radial-gradient(ellipse 80% 60% at 20% -10%, rgba(0, 113, 227, 0.08) 0%, transparent 60%),
    radial-gradient(ellipse 60% 40% at 80% 110%, rgba(0, 113, 227, 0.06) 0%, transparent 60%);
}

a {
  color: inherit;
}

#siteHeader {
  position: sticky;
  top: 0;
  z-index: 30;
  width: 100%;
  border-bottom: 1px solid var(--border);
  background: var(--surface-strong);
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.04);
}

.topbar {
  max-width: 1160px;
  margin: 0 auto;
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  border-radius: var(--radius-pill);
  font-size: 16px;
  font-weight: 600;
  letter-spacing: -0.01em;
  white-space: nowrap;
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.34);
  border: 1px solid rgba(255, 255, 255, 0.18);
  text-decoration: none;
  transition: border-color 0.2s ease, background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.brand:hover {
  transform: translateY(-1px);
  background: rgba(255, 255, 255, 0.5);
}

.nav {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
  flex-wrap: nowrap;
}

.nav-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 12px;
  border-radius: var(--radius-pill);
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-secondary);
  text-decoration: none;
  transition: border-color 0.2s ease, background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.nav-link:hover {
  transform: translateY(-1px);
  background: rgba(255, 255, 255, 0.34);
  color: var(--accent);
}

.nav-link.active {
  background: rgba(255, 255, 255, 0.58);
  border-color: rgba(255, 255, 255, 0.22);
  color: var(--text-primary);
}

.page,
.container {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 24px 80px;
}

.empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 72px 24px;
  border-radius: var(--radius-card);
  border: 1px solid var(--border);
  background: var(--surface);
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
  color: var(--text-tertiary);
  box-shadow: var(--shadow-sm);
}

.empty-icon {
  margin-bottom: 12px;
  font-size: 42px;
}

.empty-title {
  margin: 0 0 8px;
  color: var(--text-primary);
  font-size: 18px;
  font-weight: 600;
}

.empty-hint {
  margin: 0;
  color: var(--text-secondary);
  font-size: 14px;
}

@keyframes fadeDown {
  from {
    opacity: 0;
    transform: translateY(-18px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(18px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes cardIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 760px) {
  .topbar {
    padding: 10px 16px;
    flex-direction: row;
    align-items: center;
    gap: 10px;
  }

  .nav {
    justify-content: flex-end;
    gap: 4px;
  }

  .brand {
    padding: 8px 10px;
    font-size: 13px;
  }

  .nav-link {
    padding: 8px 10px;
    font-size: 13px;
  }

  .page,
  .container {
    padding: 0 16px 56px;
  }
}
