:root {
  --bg: #0b0f14;
  --surface: #121820;
  --surface-2: #1a2230;
  --border: #2a3544;
  --text: #e8edf4;
  --muted: #8b98a8;
  --accent: #3b82f6;
  --accent-dim: rgba(59, 130, 246, 0.12);
  --up: #22c55e;
  --down: #ef4444;
  --radius: 12px;
  --font: "DM Sans", system-ui, sans-serif;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.55;
  color: var(--text);
  background: var(--bg);
  background-image:
    radial-gradient(ellipse 80% 50% at 50% -20%, rgba(59, 130, 246, 0.15), transparent),
    radial-gradient(ellipse 60% 40% at 100% 100%, rgba(34, 197, 94, 0.06), transparent);
}

.wrap {
  width: min(920px, calc(100% - 2rem));
  margin-inline: auto;
}

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

a:hover {
  text-decoration: underline;
}

code {
  font-size: 0.88em;
  padding: 0.15em 0.45em;
  border-radius: 4px;
  background: var(--surface-2);
  color: #cbd5e1;
}

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

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 0;
  flex-wrap: wrap;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: var(--accent-dim);
  color: var(--accent);
  font-weight: 700;
  font-size: 1.1rem;
}

.brand-name {
  margin: 0;
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
}

.brand-tag {
  margin: 0;
  font-size: 0.78rem;
  color: var(--muted);
}

.as-of {
  margin: 0;
  font-size: 0.85rem;
  color: var(--muted);
}

/* Hero */
.hero {
  padding: 2.5rem 0 1.5rem;
}

.hero h1 {
  margin: 0 0 0.5rem;
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  font-weight: 700;
  letter-spacing: -0.03em;
}

.hero-lead {
  margin: 0;
  max-width: 52ch;
  color: var(--muted);
  font-size: 1rem;
}

/* Featured card */
.featured {
  margin-bottom: 1.5rem;
}

.featured-card {
  display: grid;
  gap: 0.25rem;
  padding: 1.5rem 1.75rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: linear-gradient(145deg, var(--surface) 0%, var(--surface-2) 100%);
}

.featured-label {
  margin: 0;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.featured-value {
  margin: 0;
  font-size: clamp(2rem, 6vw, 2.75rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}

.featured-sub {
  margin: 0;
  font-size: 0.9rem;
  color: var(--muted);
}

/* Panel */
.panel {
  margin-bottom: 1.5rem;
  padding: 1.25rem 1.5rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--surface);
}

.panel-head {
  margin-bottom: 1rem;
}

.panel-head h2,
.about h2 {
  margin: 0 0 0.25rem;
  font-size: 1.1rem;
  font-weight: 600;
}

.panel-head p {
  margin: 0;
  font-size: 0.85rem;
  color: var(--muted);
}

.table-wrap {
  overflow-x: auto;
}

.indices-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
}

.indices-table th,
.indices-table td {
  padding: 0.65rem 0.5rem;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

.indices-table th.num,
.indices-table td.num {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

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

.indices-table tbody tr:hover {
  background: rgba(255, 255, 255, 0.02);
}

.indices-table .highlight {
  font-weight: 600;
  color: var(--accent);
}

/* About */
.about p {
  margin: 0 0 0.75rem;
  color: var(--muted);
  font-size: 0.92rem;
}

.about-list {
  margin: 0 0 1rem;
  padding-left: 1.25rem;
  color: var(--text);
  font-size: 0.92rem;
}

.about-list li {
  margin-bottom: 0.35rem;
}

.muted {
  font-size: 0.82rem !important;
}

.loading,
.error-msg {
  color: var(--muted);
  font-size: 0.9rem;
}

.error-msg {
  color: #fca5a5;
}

/* Footer */
.site-footer {
  margin-top: 2rem;
  padding: 1.5rem 0 2rem;
  border-top: 1px solid var(--border);
}

.site-footer p {
  margin: 0;
  font-size: 0.82rem;
  color: var(--muted);
}

@media (max-width: 520px) {
  .header-inner {
    flex-direction: column;
    align-items: flex-start;
  }
}
