:root {
  color-scheme: light dark;
  --bg: #fbfaf7;
  --fg: #1c1917;
  --muted: #6b7280;
  --line: #e7e5e4;
  --accent: #9a3412;
  --card: #fff;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #14110f;
    --fg: #f5f5f4;
    --muted: #a8a29e;
    --line: #292524;
    --accent: #fdba74;
    --card: #1c1917;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0 auto;
  max-width: 46rem;
  padding: 1.5rem 1rem 4rem;
  background: var(--bg);
  color: var(--fg);
  font: 16px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

header { margin-bottom: 1.5rem; }

h1 {
  font-size: 1.5rem;
  letter-spacing: -0.02em;
  margin: 0;
}

h1 a { color: inherit; text-decoration: none; }

.lede {
  margin: 0.25rem 0 0;
  color: var(--muted);
  font-size: 0.9375rem;
}

.controls {
  display: grid;
  gap: 0.5rem;
  grid-template-columns: 1fr 1fr;
  margin-bottom: 1rem;
}

.controls input[type="search"] { grid-column: 1 / -1; }

input,
select {
  width: 100%;
  padding: 0.65rem 0.75rem;
  font: inherit;
  color: inherit;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 0.6rem;
  appearance: none;
}

input:focus-visible,
select:focus-visible,
a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.status {
  color: var(--muted);
  font-size: 0.9375rem;
  margin: 1rem 0;
}

.month {
  margin: 2rem 0 0.5rem;
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.event {
  display: flex;
  gap: 0.9rem;
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--line);
}

.date {
  flex: 0 0 3.25rem;
  text-align: center;
  line-height: 1.1;
}

.date .d { display: block; font-size: 1.35rem; font-weight: 700; }
.date .m { display: block; font-size: 0.75rem; text-transform: uppercase; color: var(--muted); }

.body { min-width: 0; }

.title {
  font-weight: 600;
  color: inherit;
  text-decoration: none;
}

.title:hover { text-decoration: underline; }

.meta {
  font-size: 0.875rem;
  color: var(--muted);
  margin-top: 0.15rem;
}

.summary {
  font-size: 0.9375rem;
  margin: 0.3rem 0 0;
}

.badges { display: flex; gap: 0.4rem; flex-wrap: wrap; margin-top: 0.4rem; }

.badge {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 0.1rem 0.4rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
}

.badge.tentative { color: #b45309; border-color: #b45309; }

footer {
  margin-top: 3rem;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.8125rem;
}

a { color: var(--accent); }

@media (min-width: 40rem) {
  h1 { font-size: 1.75rem; }
  .controls { grid-template-columns: 1fr 12rem 12rem; }
  .controls input[type="search"] { grid-column: auto; }
}
