:root {
  --bg: #0a0a0a;
  --bg-card: #111111;
  --bg-hover: #1a1a1a;
  --border: #222222;
  --text: #e0e0e0;
  --text-dim: #666666;
  --text-muted: #444444;
  --accent: #00d4aa;
  --accent-dim: #00d4aa33;
  --red: #ff6b6b;
  --orange: #ffa64d;
  --blue: #4dabf7;
  --purple: #b197fc;
  --font-mono: 'SF Mono', 'Fira Code', 'JetBrains Mono', 'Cascadia Code', Consolas, monospace;
  --font-sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
}

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

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 14px;
  line-height: 1.6;
  min-height: 100vh;
}

/* Header */
header {
  border-bottom: 1px solid var(--border);
  padding: 1.5rem 2rem;
  position: sticky;
  top: 0;
  background: var(--bg);
  z-index: 10;
}

.header-content {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

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

.logo-icon {
  font-size: 1.5rem;
}

.logo h1 {
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.tagline {
  color: var(--text-dim);
  font-size: 0.8rem;
  font-family: var(--font-sans);
}

.status-indicator {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  color: var(--text-dim);
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--text-muted);
  transition: background 0.3s;
}

.status-dot.live {
  background: var(--accent);
  box-shadow: 0 0 8px var(--accent-dim);
  animation: pulse 2s infinite;
}

.status-dot.stale {
  background: var(--orange);
}

.status-dot.error {
  background: var(--red);
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

/* Metrics */
.metrics {
  max-width: 1200px;
  margin: 2rem auto;
  padding: 0 2rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 1rem;
}

.metric {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1.25rem;
  text-align: center;
}

.metric-value {
  display: block;
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: -0.03em;
}

.metric-label {
  display: block;
  font-size: 0.7rem;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 0.25rem;
  font-family: var(--font-sans);
}

/* Feed */
.feed-section {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem 4rem;
}

.feed-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--border);
}

.feed-header h2 {
  font-size: 1rem;
  font-weight: 600;
}

.feed-updated {
  font-size: 0.75rem;
  color: var(--text-dim);
  font-family: var(--font-sans);
}

.feed {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.feed-loading {
  color: var(--text-dim);
  text-align: center;
  padding: 3rem;
}

/* Feed entry */
.feed-entry {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1rem 1.25rem;
  transition: border-color 0.2s;
  animation: fadeIn 0.3s ease-out;
}

.feed-entry:hover {
  border-color: var(--text-muted);
}

.feed-entry.new {
  border-left: 3px solid var(--accent);
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: translateY(0); }
}

.entry-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.entry-id {
  font-weight: 600;
  color: var(--accent);
  font-size: 0.85rem;
}

.entry-project {
  font-size: 0.7rem;
  color: var(--text-dim);
  background: var(--bg-hover);
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
  font-family: var(--font-sans);
}

.entry-time {
  font-size: 0.75rem;
  color: var(--text-dim);
}

.entry-title {
  font-size: 0.9rem;
  font-weight: 500;
  margin-bottom: 0.35rem;
}

.entry-summary {
  font-size: 0.8rem;
  color: var(--text-dim);
  font-family: var(--font-sans);
  line-height: 1.5;
}

.entry-stats {
  display: flex;
  gap: 1rem;
  margin-top: 0.5rem;
  font-size: 0.75rem;
}

.stat-add {
  color: var(--accent);
}

.stat-del {
  color: var(--red);
}

.stat-agent {
  color: var(--purple);
}

.stat-model {
  color: var(--text-muted);
}

/* Footer */
footer {
  border-top: 1px solid var(--border);
  padding: 1.5rem 2rem;
  text-align: center;
  font-size: 0.75rem;
  color: var(--text-dim);
  font-family: var(--font-sans);
}

footer a {
  color: var(--text-dim);
  text-decoration: underline;
  text-underline-offset: 2px;
}

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

/* Responsive */
@media (max-width: 640px) {
  header { padding: 1rem; }
  .header-content { flex-direction: column; gap: 0.5rem; }
  .logo { flex-wrap: wrap; }
  .tagline { display: none; }
  .metrics { padding: 0 1rem; grid-template-columns: repeat(3, 1fr); gap: 0.5rem; }
  .metric { padding: 0.75rem; }
  .metric-value { font-size: 1.25rem; }
  .feed-section { padding: 0 1rem 2rem; }
  .entry-header { flex-direction: column; align-items: flex-start; gap: 0.25rem; }
}
