:root {
  --bg: #faf9f5;
  --ink: #141413;
  --mute: #73726c;
  --line: #e8e6df;
  --paper: #ffffff;
  --ok: #76ad2a;
  --warn: #d9a92a;
  --partial: #f08230;
  --down: #e04343;
  --nodata: #e6e6e6;
  --status-ok: #76ad2a;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--ink);
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.5;
}

.page {
  max-width: 890px;
  margin: 0 auto;
  padding: 36px 24px 80px;
}

.mast {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
}

.brand {
  font-size: 26px;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: inherit;
  text-decoration: none;
}

.page-status {
  background: #b0b0b0;
  color: #fff;
  border-radius: 5px;
  padding: 18px 22px;
  margin-bottom: 28px;
}

.page-status h2 {
  margin: 0;
  font-size: 20px;
  font-weight: 500;
}

.page-status[data-status="operational"] { background: var(--ok); }
.page-status[data-status="degraded"] { background: var(--warn); }
.page-status[data-status="partial_outage"] { background: var(--partial); }
.page-status[data-status="major_outage"],
.page-status[data-status="outage"] { background: var(--down); }

.uptime-caption {
  margin: 0 0 8px;
  text-align: right;
  font-size: 13px;
  color: var(--mute);
}

.components {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 4px;
}

.component {
  padding: 16px 18px 14px;
  border-bottom: 1px solid var(--line);
}

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

.component.child {
  padding-left: 36px;
  background: #fcfcfa;
}

.component-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.component-head .name {
  font-size: 16px;
  font-weight: 500;
  color: var(--ink);
  text-decoration: none;
}

.component-head .name:hover { text-decoration: underline; }

.component-head .status {
  font-size: 14px;
  color: var(--mute);
  white-space: nowrap;
}

.component-head .status.operational { color: var(--status-ok); }
.component-head .status.degraded { color: var(--warn); }
.component-head .status.partial_outage { color: var(--partial); }
.component-head .status.outage,
.component-head .status.major_outage { color: var(--down); }

.bars {
  display: flex;
  gap: 2px;
  height: 34px;
  width: 100%;
}

.bar {
  flex: 1 1 0;
  min-width: 0;
  height: 34px;
  border-radius: 1px;
  background: var(--nodata);
  cursor: default;
}

.bar:hover { filter: brightness(0.88); }

.bar-meta {
  display: grid;
  grid-template-columns: auto 1fr auto 1fr auto;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
  font-size: 12px;
  color: var(--mute);
}

.bar-meta .rule {
  height: 1px;
  background: var(--line);
}

.bar-meta .pct {
  text-align: center;
  white-space: nowrap;
}

.incidents-wrap {
  margin-top: 48px;
}

.incidents-wrap > h2 {
  margin: 0 0 18px;
  font-size: 26px;
  font-weight: 500;
  letter-spacing: -0.02em;
}

.incident-day {
  margin-bottom: 22px;
}

.incident-day h3 {
  margin: 0 0 8px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
  font-size: 16px;
  font-weight: 600;
}

.incident-day .none {
  margin: 0;
  color: var(--mute);
  font-size: 14px;
}

.incident {
  margin: 0 0 16px;
}

.incident h4 {
  margin: 0 0 6px;
  font-size: 16px;
  font-weight: 600;
}

.incident .update {
  margin: 0 0 8px;
  font-size: 14px;
  color: var(--ink);
}

.incident .update strong { font-weight: 600; }

.incident .when {
  display: block;
  margin-top: 2px;
  color: var(--mute);
  font-size: 13px;
}

.colophon {
  margin-top: 48px;
  color: var(--mute);
  font-size: 13px;
}

.tip {
  position: fixed;
  z-index: 20;
  max-width: 260px;
  padding: 8px 10px;
  background: #2b2b28;
  color: #fff;
  font-size: 12px;
  line-height: 1.35;
  border-radius: 3px;
  pointer-events: none;
  transform: translate(-50%, calc(-100% - 10px));
}

@media (max-width: 640px) {
  .page { padding: 24px 16px 64px; }
  .brand { font-size: 22px; }
  .component.child { padding-left: 18px; }
  .bars { height: 28px; }
  .bar { height: 28px; }
}
