@font-face {
  font-family: "Manrope";
  src: url("/assets/manrope-latin.woff2") format("woff2");
  font-display: swap;
  font-style: normal;
  font-weight: 400 800;
}

@font-face {
  font-family: "Noto Sans SC";
  src: url("/assets/noto-sans-sc-700.woff2") format("woff2");
  font-display: swap;
  font-style: normal;
  font-weight: 700;
}

:root {
  color-scheme: dark;
  --void: #050710;
  --panel: #090d1a;
  --ink: #f4f7ff;
  --muted: #aab5ca;
  --faint: #78849a;
  --line: rgba(151, 177, 222, 0.18);
  --line-strong: rgba(156, 192, 243, 0.34);
  --cyan: #7ce7ff;
  --violet: #9d8cff;
  --green: #66f2a7;
  --amber: #ffb85c;
  --red: #ff6b78;
  --edge: clamp(22px, 4vw, 64px);
}

* { box-sizing: border-box; }

html,
body { min-width: 320px; min-height: 100%; }

body {
  margin: 0;
  min-height: 100svh;
  color: var(--ink);
  background:
    linear-gradient(rgba(124, 231, 255, 0.034) 1px, transparent 1px),
    linear-gradient(90deg, rgba(124, 231, 255, 0.034) 1px, transparent 1px),
    radial-gradient(circle at 22% 38%, rgba(0, 141, 176, 0.1), transparent 31rem),
    radial-gradient(circle at 80% 56%, rgba(75, 91, 189, 0.15), transparent 34rem),
    var(--void);
  background-size: 64px 64px, 64px 64px, auto, auto, auto;
  font-family: "Manrope", "Noto Sans SC", "PingFang SC", sans-serif;
  -webkit-font-smoothing: antialiased;
}

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

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 10;
  padding: 10px 14px;
  color: var(--void);
  background: var(--cyan);
  transform: translateY(-160%);
}

.skip-link:focus { transform: translateY(0); }

:focus-visible { outline: 2px solid var(--cyan); outline-offset: 5px; }

header {
  width: min(1440px, 100%);
  margin: 0 auto;
  min-height: 78px;
  padding: 20px var(--edge);
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.12em;
}

.brand svg { width: 28px; height: 28px; color: var(--cyan); }

.region {
  color: var(--faint);
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.13em;
}

main { width: min(1440px, 100%); margin: 0 auto; }

.summary {
  min-height: calc(100svh - 78px);
  padding: clamp(54px, 8vw, 120px) var(--edge);
  display: grid;
  grid-template-columns: minmax(300px, 0.82fr) minmax(560px, 1.18fr);
  align-items: center;
  gap: clamp(54px, 9vw, 140px);
}

.summary-copy { position: relative; padding-left: 34px; }

.summary-copy::before {
  content: "";
  position: absolute;
  top: 3px;
  bottom: 2px;
  left: 0;
  width: 1px;
  background: linear-gradient(var(--cyan), var(--line) 65%, transparent);
}

.signal-state {
  position: absolute;
  top: 6px;
  left: -5px;
  width: 11px;
  height: 11px;
  border: 2px solid var(--void);
  border-radius: 50%;
  background: var(--faint);
  box-shadow: 0 5px 18px rgba(120, 132, 154, 0.28);
}

.summary-copy[data-state="operational"] .signal-state { background: var(--green); box-shadow: 0 5px 18px rgba(102, 242, 167, 0.3); }
.summary-copy[data-state="degraded"] .signal-state,
.summary-copy[data-state="stale"] .signal-state { background: var(--amber); box-shadow: 0 5px 18px rgba(255, 184, 92, 0.28); }
.summary-copy[data-state="outage"] .signal-state,
.summary-copy[data-state="unavailable"] .signal-state { background: var(--red); box-shadow: 0 5px 18px rgba(255, 107, 120, 0.28); }

h1 {
  max-width: 7.8em;
  margin: 0;
  font-size: clamp(3rem, 5.8vw, 5.5rem);
  line-height: 0.98;
  letter-spacing: -0.04em;
  text-wrap: balance;
}

.summary-copy > p {
  max-width: 29rem;
  margin: 28px 0 0;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.8;
}

.freshness {
  margin-top: 52px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.freshness span,
.freshness time {
  font-size: 0.64rem;
  font-weight: 800;
  letter-spacing: 0.12em;
}

.freshness span { color: var(--faint); }
.freshness time { color: var(--cyan); }

.service-board {
  position: relative;
  background: rgba(8, 12, 25, 0.68);
  border-top: 1px solid var(--line-strong);
  border-bottom: 1px solid var(--line-strong);
}

.service-board::before {
  content: "";
  position: absolute;
  top: -1px;
  right: 0;
  width: 22%;
  height: 1px;
  background: var(--cyan);
  animation: signal-width 5s cubic-bezier(0.22, 1, 0.36, 1) infinite alternate;
}

.service {
  min-height: 118px;
  padding: 24px clamp(20px, 3vw, 36px);
  display: grid;
  grid-template-columns: 72px 1fr 82px 86px;
  align-items: center;
  gap: 18px;
  border-bottom: 1px solid var(--line);
  transition: background 180ms ease;
}

.service:hover { background: rgba(124, 231, 255, 0.045); }

.service-code,
.service-status,
.service-latency,
.board-foot {
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.11em;
}

.service-code { color: var(--cyan); }
.service-name { display: flex; flex-direction: column; gap: 7px; }
.service-name strong { font-size: 1.05rem; letter-spacing: -0.015em; }
.service-name small { color: var(--faint); font-size: 0.72rem; }
.service-latency { color: var(--muted); text-align: right; }
.service-status { color: var(--faint); text-align: right; }
.service[data-state="operational"] .service-status { color: var(--green); }
.service[data-state="degraded"] .service-status,
.service[data-state="stale"] .service-status { color: var(--amber); }
.service[data-state="outage"] .service-status,
.service[data-state="unavailable"] .service-status { color: var(--red); }

.board-foot {
  min-height: 64px;
  padding: 0 clamp(20px, 3vw, 36px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--faint);
}

.board-foot a { color: var(--ink); letter-spacing: 0; transition: color 180ms ease; }
.board-foot a:hover { color: var(--cyan); }

noscript {
  position: fixed;
  right: 16px;
  bottom: 16px;
  max-width: calc(100% - 32px);
  padding: 12px 16px;
  color: var(--void);
  background: var(--amber);
  font-weight: 700;
}

@keyframes signal-width {
  from { width: 12%; }
  to { width: 42%; }
}

@media (max-width: 920px) {
  .summary {
    min-height: auto;
    grid-template-columns: 1fr;
    gap: 54px;
  }

  h1 { max-width: 11em; }
}

@media (max-width: 640px) {
  :root { --edge: 20px; }

  body { background-size: 40px 40px, 40px 40px, auto, auto, auto; }
  header { min-height: 66px; padding-block: 16px; }
  .region { display: none; }

  .summary {
    min-height: calc(100svh - 66px);
    padding-block: 46px 34px;
    gap: 40px;
    align-content: center;
  }

  .summary-copy { padding-left: 24px; }
  h1 { font-size: clamp(2.65rem, 13vw, 3.65rem); }
  .summary-copy > p { margin-top: 18px; font-size: 0.9rem; line-height: 1.7; }
  .freshness { margin-top: 30px; }

  .service { min-height: 92px; padding-block: 18px; grid-template-columns: 58px 1fr auto; gap: 12px; }
  .service-latency { display: none; }
  .service-status { min-width: 56px; }
  .service-name strong { font-size: 0.92rem; }
  .service-name small { font-size: 0.65rem; }
  .board-foot { min-height: 56px; }
}

@media (max-height: 700px) and (max-width: 640px) {
  .summary { padding-top: 30px; gap: 28px; }
  .summary-copy > p { margin-top: 14px; }
  .freshness { margin-top: 20px; }
  .service { min-height: 78px; padding-block: 14px; }
  .board-foot { min-height: 50px; }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

