:root {
  color-scheme: light dark;
  --bg: #f8f8fa;
  --surface: #ffffff;
  --text: #16161b;
  --muted: #565660;
  --border: #e1e1e7;
  --link: #6d28d9;
  --operational: #2f7d57;
  --degraded_performance: #a16207;
  --partial_outage: #c2410c;
  --major_outage: #c6433f;
  --under_maintenance: #2563a8;
  --none: #e1e1e7;
  --unknown: #6b6b76;
  --font:
    'Hanken Grotesk', ui-sans-serif, system-ui, -apple-system, 'Segoe UI',
    sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b0b0e;
    --surface: #16161b;
    --text: #f1f1f4;
    --muted: #a6a6b0;
    --border: #26262d;
    --link: #b49cfb;
    --operational: #3fb27f;
    --degraded_performance: #eab308;
    --partial_outage: #f97316;
    --major_outage: #f05f5a;
    --under_maintenance: #60a5fa;
    --none: #3c3c45;
    --unknown: #a6a6b0;
  }
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 15px/1.5 var(--font);
  -webkit-font-smoothing: antialiased;
}

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

a:focus-visible {
  outline: 2px solid var(--link);
  outline-offset: 2px;
  border-radius: 2px;
}

.page {
  max-width: 760px;
  margin: 0 auto;
  padding: 24px 16px 48px;
}

.top {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 32px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-weight: 700;
  font-size: 20px;
  letter-spacing: -0.015em;
  text-decoration: none;
}

.brand img {
  border-radius: 6px;
}

.top-label {
  color: var(--muted);
  font-size: 20px;
}

.top nav {
  margin-left: auto;
  display: flex;
  gap: 16px;
  font-size: 14px;
}

.is-operational {
  --s: var(--operational);
}

.is-degraded_performance {
  --s: var(--degraded_performance);
}

.is-partial_outage {
  --s: var(--partial_outage);
}

.is-major_outage {
  --s: var(--major_outage);
}

.is-under_maintenance {
  --s: var(--under_maintenance);
}

.is-none {
  --s: var(--none);
}

.is-unknown {
  --s: var(--unknown);
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px 24px;
  margin-bottom: 16px;
}

.summary {
  border-left: 6px solid var(--s);
}

.summary h1 {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0;
  font-size: 25px;
  line-height: 1.2;
  letter-spacing: -0.015em;
}

.summary h1::before {
  content: '';
  flex: none;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--s);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--s) 20%, transparent);
}

.updated,
.quiet,
.legend,
.description,
.meta {
  color: var(--muted);
}

.updated {
  margin: 8px 0 0 26px;
  font-size: 13px;
}

.notice {
  margin: 12px 0 0 26px;
}

.stale {
  border: 1px solid var(--degraded_performance);
  border-radius: 12px;
  padding: 12px 16px;
  margin: 0 0 16px;
  background: color-mix(
    in srgb,
    var(--degraded_performance) 10%,
    var(--surface)
  );
}

section {
  margin-top: 40px;
}

h2 {
  font-size: 18px;
  letter-spacing: -0.015em;
  margin: 0 0 12px;
}

.incident {
  border-left: 4px solid var(--s);
}

.incident h3 {
  margin: 0 0 4px;
  font-size: 18px;
}

.incident .meta {
  margin: 0 0 12px;
  font-size: 13px;
}

.updates {
  list-style: none;
  margin: 0;
  padding: 0;
}

.updates li {
  padding: 12px 0;
  border-top: 1px solid var(--border);
}

.updates p {
  margin: 4px 0;
}

.updates time {
  color: var(--muted);
  font-size: 13px;
}

.components {
  list-style: none;
  margin: 0;
}

.component {
  padding: 16px 0;
  border-top: 1px solid var(--border);
}

.component:first-child {
  border-top: 0;
  padding-top: 0;
}

.component:last-child {
  padding-bottom: 0;
}

.component-head {
  display: flex;
  align-items: baseline;
  gap: 12px;
}

.component-head h3 {
  margin: 0;
  font-size: 15px;
}

.badge {
  margin-left: auto;
  color: var(--s);
  font-weight: 600;
  font-size: 13px;
  white-space: nowrap;
}

.description {
  margin: 2px 0 10px;
  font-size: 13px;
}

.bars {
  display: flex;
  gap: 2px;
  height: 32px;
}

.bar {
  flex: 1;
  min-width: 2px;
  border-radius: 2px;
  background: var(--s);
}

.bar:hover {
  opacity: 0.7;
}

.legend {
  display: flex;
  justify-content: space-between;
  margin-top: 6px;
  font-size: 12px;
}

.legend .short {
  display: none;
}

.day {
  font-size: 14px;
  margin: 16px 0 4px;
  padding-bottom: 4px;
  border-bottom: 1px solid var(--border);
}

.day + .quiet {
  margin: 0;
  font-size: 13px;
}

.past {
  list-style: none;
  margin: 0;
  padding: 0;
}

.past li {
  margin: 6px 0;
}

.past .meta {
  font-size: 13px;
}

.footer {
  margin-top: 48px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  color: var(--muted);
  font-size: 13px;
}

@media (max-width: 600px) {
  .card {
    padding: 16px;
  }

  .summary h1 {
    font-size: 20px;
  }

  .bar:nth-child(-n + 60) {
    display: none;
  }

  .legend .long {
    display: none;
  }

  .legend .short {
    display: inline;
  }
}
