:root {
  --bg: #f5f5f3;
  --bg-raised: #ffffff;
  --ink: #15161a;
  --ink-soft: #5f636b;
  --ink-faint: #9a9ea6;
  --line: #e1e1dd;
  --line-strong: #cfcfca;
  --brand: #d4ff00;
  --accent: #d4ff00;
  --accent-text: #5a7000;
  --accent-soft: rgba(212, 255, 0, 0.32);
  --accent-ring: rgba(90, 112, 0, 0.18);
  --icon: #15161a;
  --down: #c2410c;
  --down-soft: rgba(194, 65, 12, 0.12);
  --glow: transparent;
  --font-display: "Inter Tight", "Inter", system-ui, sans-serif;
  --font-body: "Inter", system-ui, -apple-system, sans-serif;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1112;
    --bg-raised: #161819;
    --ink: #ecedee;
    --ink-soft: #9ba0a6;
    --ink-faint: #5f656c;
    --line: #22272c;
    --line-strong: #30363c;
    --accent: #d4ff00;
    --accent-text: #d9ff33;
    --accent-soft: rgba(212, 255, 0, 0.11);
    --accent-ring: rgba(212, 255, 0, 0.22);
    --icon: #d4ff00;
    --down: #f28b5b;
    --down-soft: rgba(242, 139, 91, 0.14);
    --glow: rgba(212, 255, 0, 0.06);
    color-scheme: dark;
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

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

:focus-visible {
  outline: 2px solid var(--accent-text);
  outline-offset: 3px;
}

/* Header */

.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: min(100% - 32px, 1040px);
  margin: 0 auto;
  padding: 28px 0 0;
}

.wordmark {
  display: inline-flex;
  align-items: center;
}

.logo {
  display: block;
  height: 46px;
  width: auto;
}

.clock {
  font-variant-numeric: tabular-nums;
  color: var(--ink-soft);
  font-size: 14px;
}

/* Hero */

.page {
  flex: 1;
  width: min(100% - 32px, 1040px);
  margin: 0 auto;
}

.hero {
  position: relative;
  padding: clamp(72px, 14vh, 140px) 0 clamp(40px, 6vh, 64px);
}

.hero::before {
  content: "";
  position: absolute;
  inset: -120px -200px auto -200px;
  height: 420px;
  background: radial-gradient(closest-side, var(--glow), transparent);
  pointer-events: none;
  z-index: -1;
}

.headline {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(38px, 7vw, 76px);
  line-height: 1.02;
  letter-spacing: -0.035em;
  max-width: 14ch;
  text-wrap: balance;
}

.headline[data-state="down"] {
  color: var(--down);
}

.lede {
  margin: 22px 0 0;
  max-width: 46ch;
  font-size: 16px;
  color: var(--ink-soft);
}

/* Grid of services: shared hairlines rather than boxed cards */

.grid {
  list-style: none;
  margin: 0 0 56px;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}

.cell {
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.cell-wide {
  grid-column: span 2;
}

.cell a {
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 200px;
  padding: 22px 22px 20px;
  background: var(--bg);
  transition: background-color 160ms ease;
}

.cell a:hover {
  background: var(--bg-raised);
}

.cell a:focus-visible {
  outline-offset: -2px;
  z-index: 1;
}

.icon {
  display: inline-flex;
  width: 36px;
  height: 36px;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: var(--accent-soft);
  color: var(--icon);
  margin-bottom: 26px;
}

.icon svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 19px;
  letter-spacing: -0.015em;
  line-height: 1.2;
}

.desc {
  margin-top: 4px;
  color: var(--ink-soft);
}

.meta {
  margin-top: auto;
  padding-top: 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-size: 13px;
  color: var(--ink-faint);
}

.host {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  flex-shrink: 0;
  color: var(--ink-faint);
}

.status i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--line-strong);
}

.status[data-state="online"] {
  color: var(--accent-text);
}

.status[data-state="online"] i {
  background: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-ring);
}

.status[data-state="down"] {
  color: var(--down);
}

.status[data-state="down"] i {
  background: var(--down);
  box-shadow: 0 0 0 3px var(--down-soft);
}

.cell[data-state="down"] .icon {
  background: var(--down-soft);
  color: var(--down);
}

kbd {
  position: absolute;
  top: 22px;
  right: 22px;
  font-family: var(--font-body);
  font-size: 12px;
  color: var(--ink-faint);
  border: 1px solid var(--line);
  border-radius: 5px;
  padding: 1px 6px;
  opacity: 0;
  transition: opacity 160ms ease;
}

.cell a:hover kbd,
.cell a:focus-visible kbd {
  opacity: 1;
}

@media (hover: none) {
  kbd {
    display: none;
  }
}

/* Footer */

.foot {
  width: min(100% - 32px, 1040px);
  margin: 0 auto;
  padding: 0 0 36px;
  color: var(--ink-faint);
  font-size: 13px;
}

.foot p {
  margin: 0;
  max-width: 60ch;
}

.checked {
  margin-top: 6px !important;
  font-variant-numeric: tabular-nums;
}

/* Responsive */

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

@media (max-width: 540px) {
  .grid {
    grid-template-columns: 1fr;
  }

  .cell-wide {
    grid-column: auto;
  }

  .logo {
    height: 38px;
  }

  .cell a {
    min-height: 0;
    padding: 20px 18px;
  }

  .icon {
    margin-bottom: 18px;
  }

  .hero {
    padding-top: 56px;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
  }
}
