:root {
  --bg: #fafbfc;
  --surface: #ffffff;
  --border: #e6e8ec;
  --text: #1f2328;
  --text-muted: #57606a;
  --accent: #2563eb;
  --accent-hover: #1d4ed8;
  --accent-soft: #eff6ff;
  --tag-simple: #ecfdf5;
  --tag-simple-fg: #047857;
  --tag-compound: #eff6ff;
  --tag-compound-fg: #1d4ed8;
  --tag-character: #fef3c7;
  --tag-character-fg: #b45309;
  --tag-scene: #fce7f3;
  --tag-scene-fg: #be185d;
  --tag-detail: #ede9fe;
  --tag-detail-fg: #6d28d9;
  --tag-abstract: #f3f4f6;
  --tag-abstract-fg: #374151;
  --shadow: 0 1px 2px rgba(31, 35, 40, 0.04), 0 4px 12px rgba(31, 35, 40, 0.04);
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans TC", "PingFang TC", "Microsoft JhengHei", Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.container {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Hero */
.hero {
  background: linear-gradient(180deg, #ffffff 0%, #f5f7fb 100%);
  border-bottom: 1px solid var(--border);
  padding: 72px 0 56px;
  text-align: center;
}

.tagline {
  display: inline-block;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--accent-soft);
  padding: 6px 12px;
  border-radius: 999px;
  margin: 0 0 20px;
  font-weight: 600;
}

.hero h1 {
  font-size: 48px;
  font-weight: 700;
  margin: 0 0 16px;
  letter-spacing: -0.02em;
}

.subtitle {
  font-size: 18px;
  color: var(--text-muted);
  margin: 0 0 32px;
}

.cta-row {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

.btn {
  display: inline-block;
  padding: 10px 20px;
  border-radius: 8px;
  font-weight: 500;
  font-size: 15px;
  transition: all 0.15s ease;
  border: 1px solid transparent;
}

.btn-primary {
  background: var(--accent);
  color: white;
}

.btn-primary:hover {
  background: var(--accent-hover);
  text-decoration: none;
}

.btn-ghost {
  background: var(--surface);
  color: var(--text);
  border-color: var(--border);
}

.btn-ghost:hover {
  background: var(--accent-soft);
  border-color: var(--accent);
  color: var(--accent);
  text-decoration: none;
}

/* Sections */
main {
  padding: 56px 0;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 32px;
  margin-bottom: 32px;
  box-shadow: var(--shadow);
}

h2 {
  margin: 0 0 16px;
  font-size: 24px;
  letter-spacing: -0.01em;
}

h3 {
  margin: 0 0 8px;
  font-size: 17px;
}

.muted {
  color: var(--text-muted);
  font-size: 14px;
}

/* Metric grid */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 32px;
}

.metric-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 24px;
  box-shadow: var(--shadow);
}

.metric-card .range {
  margin-top: 12px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 13px;
  color: var(--text-muted);
}

.metric-card p {
  margin: 0;
  color: var(--text-muted);
  font-size: 14px;
}

/* Table */
.table-wrap {
  margin-top: 20px;
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

thead th {
  text-align: left;
  padding: 12px 16px;
  background: #f6f8fa;
  font-weight: 600;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border);
  text-transform: uppercase;
  font-size: 11px;
  letter-spacing: 0.08em;
}

tbody td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
}

tbody tr:last-child td {
  border-bottom: none;
}

tbody tr:hover {
  background: #f9fafb;
}

tbody td:first-child {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 13px;
  color: var(--text-muted);
}

.tag {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 500;
}

.tag-simple    { background: var(--tag-simple);    color: var(--tag-simple-fg); }
.tag-compound  { background: var(--tag-compound);  color: var(--tag-compound-fg); }
.tag-character { background: var(--tag-character); color: var(--tag-character-fg); }
.tag-scene     { background: var(--tag-scene);     color: var(--tag-scene-fg); }
.tag-detail    { background: var(--tag-detail);    color: var(--tag-detail-fg); }
.tag-abstract  { background: var(--tag-abstract);  color: var(--tag-abstract-fg); }

/* Status */
.status-card .dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  margin-right: 8px;
  vertical-align: middle;
}

.dot-pending {
  background: #f59e0b;
  box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.15);
}

/* Footer */
footer {
  border-top: 1px solid var(--border);
  padding: 24px 0;
  background: var(--surface);
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--text-muted);
  font-size: 14px;
}

/* Responsive */
@media (max-width: 720px) {
  .hero {
    padding: 56px 0 40px;
  }
  .hero h1 {
    font-size: 36px;
  }
  .subtitle {
    font-size: 16px;
  }
  .grid-3 {
    grid-template-columns: 1fr;
  }
  .card {
    padding: 24px;
  }
}
