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

:root {
  --bg: #0b1020;
  --surface: #141a2e;
  --border: #232b45;
  --text: #e6e9f2;
  --muted: #8b93aa;
  --accent: #4f8cff;
  --accent-strong: #2f6bff;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Microsoft YaHei", Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
}

.container {
  max-width: 860px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  background: rgba(11, 16, 32, 0.85);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
  z-index: 10;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text);
  font-weight: 700;
  font-size: 18px;
}

.brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--accent), #7b5cff);
  color: #fff;
  font-size: 14px;
  font-weight: 800;
}

.nav {
  display: flex;
  gap: 20px;
}

.nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 14px;
  transition: color 0.2s;
}

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

/* Hero */
.hero {
  padding: 64px 0 40px;
  text-align: center;
  background:
    radial-gradient(circle at 20% 20%, rgba(79, 140, 255, 0.12), transparent 40%),
    radial-gradient(circle at 80% 60%, rgba(123, 92, 255, 0.1), transparent 40%);
}

.hero h1 {
  font-size: 36px;
  letter-spacing: -0.5px;
}

.hero-sub {
  margin-top: 14px;
  color: var(--muted);
  font-size: 16px;
  max-width: 640px;
  margin-inline: auto;
}

/* Search */
.search-section {
  padding: 24px 20px 48px;
}

.search-section h2 {
  font-size: 24px;
  margin-bottom: 6px;
}

.muted {
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 18px;
}

.search-bar {
  display: flex;
  gap: 10px;
}

.search-bar input {
  flex: 1;
  padding: 12px 16px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  font-size: 15px;
  outline: none;
  transition: border-color 0.2s;
}

.search-bar input:focus {
  border-color: var(--accent);
}

.search-bar button {
  padding: 12px 24px;
  border: none;
  border-radius: 10px;
  background: var(--accent);
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
}

.search-bar button:hover {
  background: var(--accent-strong);
}

.search-bar button:disabled {
  background: #2a3554;
  cursor: not-allowed;
}

.search-status {
  margin-top: 16px;
  color: var(--muted);
  font-size: 14px;
}

.search-results {
  margin-top: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.result-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px 20px;
  transition: border-color 0.2s, transform 0.15s;
}

.result-card:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
}

.result-card h4 {
  font-size: 16px;
  margin-bottom: 4px;
}

.result-card h4 a {
  color: var(--text);
  text-decoration: none;
}

.result-card h4 a:hover {
  color: var(--accent);
}

.result-card p {
  color: var(--muted);
  font-size: 14px;
}

.result-score {
  display: inline-block;
  margin-top: 8px;
  padding: 2px 10px;
  border-radius: 20px;
  background: rgba(79, 140, 255, 0.15);
  color: var(--accent);
  font-size: 12px;
  font-weight: 600;
}

/* Docs */
.docs-section,
.about-section {
  padding: 32px 20px 48px;
}

.docs-section h2,
.about-section h2 {
  font-size: 24px;
  margin-bottom: 20px;
}

.doc-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 18px 22px;
  margin-bottom: 14px;
}

.doc-card h3 {
  font-size: 17px;
  margin-bottom: 6px;
}

.doc-card h3 a {
  color: var(--text);
  text-decoration: none;
}

.doc-card h3 a:hover {
  color: var(--accent);
}

.doc-card p {
  color: var(--muted);
  font-size: 14px;
}

.tag {
  display: inline-block;
  margin-top: 10px;
  padding: 3px 12px;
  border-radius: 20px;
  background: rgba(96, 165, 250, 0.12);
  border: 1px solid rgba(96, 165, 250, 0.25);
  color: #7fb4ff;
  font-size: 12px;
  font-weight: 600;
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 20px 0;
  text-align: center;
  color: var(--muted);
  font-size: 13px;
}

@media (max-width: 640px) {
  .hero h1 {
    font-size: 28px;
  }
  .hero-sub {
    font-size: 14px;
  }
}