/* Dark board of vendor cards. Colour carries one meaning only — how bad it is
   — so the marks stay the brightest thing on their card. */

:root {
  --bg: #08090c;
  --card: #101218;
  --card-lift: #141720;
  --line: #1d212a;
  --line-soft: #171a22;
  --text: #eef1f6;
  --dim: #8b93a3;
  --faint: #5b6473;
  --ok: #4ade80;
  --warn: #fbbf24;
  --bad: #f87171;
  --work: #7dd3fc;
  --radius: 16px;
}

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

html {
  background: var(--bg);
}

body {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, Roboto, Arial, sans-serif;
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  font-variant-numeric: tabular-nums;
}

.glow {
  position: fixed;
  inset: -30vh 0 auto 0;
  height: 80vh;
  pointer-events: none;
  z-index: 0;
  background: radial-gradient(50% 50% at 50% 40%, rgba(74, 222, 128, 0.13), transparent 70%);
  transition: background 0.8s ease;
}

body[data-tone='warn'] .glow {
  background: radial-gradient(50% 50% at 50% 40%, rgba(251, 191, 36, 0.14), transparent 70%);
}

body[data-tone='bad'] .glow {
  background: radial-gradient(50% 50% at 50% 40%, rgba(248, 113, 113, 0.16), transparent 70%);
}

.top,
main,
.foot {
  position: relative;
  z-index: 1;
  width: min(1180px, 100%);
  margin: 0 auto;
  padding-inline: clamp(16px, 4vw, 32px);
}

/* ── top ────────────────────────────────────────────────────────────── */

.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-block: 20px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 9px;
  background: var(--text);
  color: #000;
  font-size: 13px;
  font-weight: 700;
}

.top-right {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--dim);
}

.live-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--faint);
}

.live-dot.on {
  background: var(--ok);
  box-shadow: 0 0 0 3px rgba(74, 222, 128, 0.16);
}

.live-dot.off {
  background: var(--bad);
}

/* ── hero ───────────────────────────────────────────────────────────── */

.hero {
  padding: clamp(28px, 6vw, 60px) 0 clamp(20px, 4vw, 34px);
  text-align: center;
}

.hero-title {
  font-size: clamp(28px, 5vw, 46px);
  font-weight: 650;
  letter-spacing: -0.03em;
  line-height: 1.08;
  text-wrap: balance;
}

.hero-sub {
  max-width: 760px;
  margin: 10px auto 0;
  color: var(--dim);
  font-size: clamp(14px, 1.6vw, 16px);
}

.tally {
  display: inline-flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: 18px;
}

.tally-item {
  padding: 6px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--card);
  font-size: 13px;
  color: var(--dim);
}

.tally-item b {
  color: var(--text);
  font-weight: 600;
}

.tally-item.ok b {
  color: var(--ok);
}

.tally-item.warn b {
  color: var(--warn);
}

/* ── bands ──────────────────────────────────────────────────────────── */

.band {
  padding-bottom: 8px;
}

.band-title {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin: 26px 0 12px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--faint);
}

.band-title.warn {
  color: var(--warn);
}

.band-count {
  padding: 1px 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--dim);
}

/* ── cards ──────────────────────────────────────────────────────────── */

/* Cards inside a band. The band itself is a plain block, so bands stack and
   only their cards form a grid. */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 12px;
  align-items: start;
}

#grid {
  padding-bottom: 40px;
}

.card {
  padding: 16px 18px;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: linear-gradient(180deg, var(--card-lift), var(--card));
  animation: rise 0.45s cubic-bezier(0.2, 0.8, 0.3, 1) both;
}

.card.warn {
  border-color: rgba(251, 191, 36, 0.35);
}

.card.bad {
  border-color: rgba(248, 113, 113, 0.4);
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
}

.card-head {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo {
  flex: none;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 11px;
  background: #ffffff0a;
  box-shadow: inset 0 0 0 1px #ffffff12;
  overflow: hidden;
}

.logo img {
  width: 26px;
  height: 26px;
  object-fit: contain;
}

.logo.letter {
  font-weight: 700;
  font-size: 17px;
  color: var(--dim);
}

.card-titles {
  min-width: 0;
  margin-right: auto;
}

.card-name {
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--text);
  text-decoration: none;
}

.card-name:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.card-note {
  font-size: 13px;
  color: var(--faint);
}

.pill {
  flex: none;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  background: #ffffff0d;
  color: var(--dim);
}

.pill.ok {
  background: rgba(74, 222, 128, 0.12);
  color: var(--ok);
}

.pill.warn {
  background: rgba(251, 191, 36, 0.14);
  color: var(--warn);
}

.pill.bad {
  background: rgba(248, 113, 113, 0.14);
  color: var(--bad);
}

.pill.work {
  background: rgba(125, 211, 252, 0.14);
  color: var(--work);
}

.card-said {
  margin-top: 12px;
  font-size: 13px;
  color: var(--dim);
}

/* Whose word this is: the vendor's status page, or our own probe. */
.card-how {
  margin-top: 2px;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--faint);
}

/* ── components ─────────────────────────────────────────────────────── */

.components {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line-soft);
  display: grid;
  gap: 6px;
}

.component {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  /* A grid item defaults to min-width: auto and so refuses to be narrower than
     its content; without this a long component name overflows the card. */
  min-width: 0;
}

.dot {
  flex: none;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--faint);
}

.dot.ok {
  background: var(--ok);
}

.dot.warn {
  background: var(--warn);
}

.dot.bad {
  background: var(--bad);
}

.dot.work {
  background: var(--work);
}

.component-name {
  margin-right: auto;
  color: var(--dim);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  /* A flex child will not shrink below its content without this, and a long
     component name would push its status off the card. */
  min-width: 0;
}

.component-state {
  flex: none;
  font-size: 12px;
  color: var(--faint);
}

.component-state.ok {
  color: var(--ok);
}

.component-state.warn {
  color: var(--warn);
}

.component-state.bad {
  color: var(--bad);
}

.component-state.work {
  color: var(--work);
}

.component-more {
  font-size: 12px;
  color: var(--faint);
}

/* ── incidents ──────────────────────────────────────────────────────── */

.incidents {
  margin-top: 12px;
  display: grid;
  gap: 8px;
}

.incident {
  padding: 11px 12px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: #00000033;
}

.incident-head {
  display: flex;
  align-items: baseline;
  gap: 8px;
  flex-wrap: wrap;
}

.incident-name {
  font-weight: 600;
  font-size: 14px;
  margin-right: auto;
}

.incident-impact {
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--warn);
}

.incident-meta {
  margin-top: 2px;
  font-size: 12px;
  color: var(--faint);
}

.incident-body {
  margin-top: 6px;
  font-size: 13px;
  color: var(--dim);
  line-height: 1.45;
}

.incident-more {
  font-size: 12px;
  color: var(--dim);
  text-decoration: none;
}

.incident-more:hover {
  color: var(--text);
}

/* ── footer ─────────────────────────────────────────────────────────── */

.foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: auto;
  padding-block: 20px;
  border-top: 1px solid var(--line-soft);
  font-size: 12px;
  color: var(--faint);
}

.foot-links {
  display: inline-flex;
  gap: 16px;
}

.foot a {
  color: var(--dim);
  text-decoration: none;
}

.foot a:hover {
  color: var(--text);
}

@media (prefers-reduced-motion: reduce) {
  .card {
    animation: none;
  }
}
