:root {
  color-scheme: dark;
  --bg: #0e1012;
  --panel: #14171c;
  --cream: #f3eadf;
  --muted: rgba(243, 234, 223, 0.72);
  --gold: #c4a574;
  --line: rgba(243, 234, 223, 0.12);
  --ok: #7dcea0;
  --warn: #e0b35c;
  --bad: #e07a6a;
  --info: #8bb4d9;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--cream);
  font-family: Inter, system-ui, -apple-system, Segoe UI, sans-serif;
  line-height: 1.55;
}

a { color: var(--gold); text-decoration: none; }
a:hover { text-decoration: underline; }

.wrap {
  width: min(1080px, calc(100% - 2rem));
  margin: 0 auto;
  padding: 1.25rem 0 3.5rem;
}

.top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1.25rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--line);
}

.brand {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.brand strong { font-size: 1.15rem; letter-spacing: 0.02em; }
.brand span { color: var(--muted); font-size: 0.85rem; }

nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1rem;
  font-size: 0.92rem;
}

nav a[aria-current="page"] {
  color: var(--cream);
  text-decoration: underline;
  text-underline-offset: 0.28em;
}

.banner {
  margin: 1.25rem 0;
  padding: 1rem 1.1rem;
  border-radius: 12px;
  background: var(--panel);
  border: 1px solid var(--line);
}

.banner.outage { border-color: rgba(224, 122, 106, 0.45); }
.banner.degraded { border-color: rgba(224, 179, 92, 0.45); }

.banner h1 {
  margin: 0 0 0.35rem;
  font-size: clamp(1.35rem, 3vw, 1.85rem);
}

@media (min-width: 860px) {
  .components { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 1rem;
  min-width: 0;
}

.card h2 {
  margin: 0 0 0.75rem;
  font-size: 1rem;
}

.components {
  display: grid;
  gap: 0.65rem;
}

.component {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.65rem 0.75rem;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.03);
}

.pill {
  flex-shrink: 0;
  border-radius: 999px;
  padding: 0.18rem 0.55rem;
  font-size: 0.75rem;
  font-weight: 650;
  text-transform: capitalize;
}

.pill.operational { color: #0e1012; background: var(--ok); }
.pill.degraded, .pill.maintenance, .pill.third-party { color: #0e1012; background: var(--warn); }
.pill.outage { color: #0e1012; background: var(--bad); }

.muted { color: var(--muted); font-size: 0.9rem; }
.note { margin: 0.75rem 0 0; font-size: 0.85rem; color: var(--muted); }

.incident, .update {
  padding: 0.85rem 0;
  border-top: 1px solid var(--line);
}

.incident:first-child, .update:first-child { border-top: 0; padding-top: 0; }

.incident h3, .update h3 {
  margin: 0 0 0.3rem;
  font-size: 1rem;
}

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

th, td {
  text-align: left;
  vertical-align: top;
  padding: 0.7rem 0.55rem;
  border-bottom: 1px solid var(--line);
}

th { color: var(--muted); font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.06em; }

@media (max-width: 720px) {
  table, thead, tbody, th, td, tr { display: block; }
  thead { display: none; }
  tr { padding: 0.85rem 0; border-bottom: 1px solid var(--line); }
  td {
    border: 0;
    padding: 0.2rem 0;
  }
  td::before {
    content: attr(data-label);
    display: block;
    color: var(--muted);
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 0.15rem;
  }
}

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