:root {
  color-scheme: dark;
  --bg: #090a0b;
  --panel: #111315;
  --panel-soft: #17191c;
  --line: #272a2e;
  --muted: #8f959c;
  --muted-2: #626a72;
  --text: #f4f5f6;
  --yellow: #ffdc00;
  --green: #62d995;
  --red: #ff7777;
  --amber: #ffc366;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; min-height: 100vh; background: var(--bg); color: var(--text); }
a { color: inherit; }
button { font: inherit; }
button:focus-visible, a:focus-visible, summary:focus-visible { outline: 2px solid var(--yellow); outline-offset: 3px; }
.shell { width: min(100% - 40px, 980px); margin: 0 auto; }
.masthead { height: 78px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; font-weight: 800; font-size: 22px; letter-spacing: -.06em; }
.brand-dot { color: var(--yellow); }
.brand-mark { height: 21px; display: flex; align-items: center; gap: 3px; }
.brand-mark i { width: 3px; border-radius: 3px; background: var(--yellow); }
.brand-mark i:nth-child(1), .brand-mark i:nth-child(5) { height: 8px; }
.brand-mark i:nth-child(2), .brand-mark i:nth-child(4) { height: 15px; }
.brand-mark i:nth-child(3) { height: 21px; }
.masthead-label, .eyebrow { color: var(--muted-2); font: 500 10px/1.4 ui-monospace, SFMono-Regular, Consolas, monospace; letter-spacing: .16em; }
.intro { display: flex; align-items: end; justify-content: space-between; gap: 28px; padding: 54px 0 28px; }
.eyebrow { margin: 0 0 13px; color: var(--yellow); }
h1, h2, h3, p { margin-top: 0; }
h1 { margin-bottom: 10px; font-size: clamp(30px, 5vw, 46px); letter-spacing: -.055em; line-height: 1.05; }
.lede { max-width: 620px; margin: 0; color: var(--muted); font-size: 15px; }
.refresh-button { display: inline-flex; align-items: center; justify-content: center; gap: 9px; min-height: 42px; flex: none; padding: 0 14px; border: 1px solid #3a3e43; border-radius: 999px; background: transparent; color: var(--text); font-size: 12px; font-weight: 700; cursor: pointer; transition: background .15s ease, border-color .15s ease; }
.refresh-button:hover { background: var(--panel-soft); border-color: #61676e; }
.refresh-button:disabled { cursor: wait; opacity: .65; }
.refresh-button svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.spinning { animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.overall { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 15px; padding: 19px 21px; border: 1px solid var(--line); border-radius: 12px; background: radial-gradient(ellipse at top left, rgba(98, 217, 149, .1), transparent 58%), var(--panel); }
.overall.down { background: radial-gradient(ellipse at top left, rgba(255, 119, 119, .1), transparent 58%), var(--panel); }
.overall.unknown { background: radial-gradient(ellipse at top left, rgba(255, 195, 102, .1), transparent 58%), var(--panel); }
.overall-icon { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: rgba(98, 217, 149, .13); color: var(--green); }
.overall-icon::after { content: '✓'; font-size: 21px; font-weight: 700; }
.overall.down .overall-icon { background: rgba(255, 119, 119, .13); color: var(--red); }
.overall.down .overall-icon::after { content: '!'; }
.overall.unknown .overall-icon { background: rgba(255, 195, 102, .13); color: var(--amber); }
.overall.unknown .overall-icon::after { content: '?'; }
.overall-copy { display: grid; gap: 4px; }
.overall-copy strong { font-size: 15px; }
.overall-copy span { color: var(--muted); font-size: 12px; }
.checked-at { color: var(--muted); font: 11px ui-monospace, SFMono-Regular, Consolas, monospace; white-space: nowrap; }
.environments { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 20px; }
.environment-card { min-width: 0; padding: 17px; border: 1px solid var(--line); border-radius: 12px; background: #0d0f10; }
.environment-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 2px 2px 15px; }
.environment-kicker { margin: 0 0 4px; color: var(--muted-2); font: 500 9px 'DM Mono', monospace; letter-spacing: .14em; }
.environment-heading h2 { margin: 0; font-size: 19px; letter-spacing: -.035em; }
.open-link { color: var(--muted); font-size: 11px; font-weight: 700; text-decoration: none; white-space: nowrap; }
.open-link:hover { color: var(--text); }
.health-banner { display: flex; align-items: center; gap: 8px; min-height: 36px; margin-bottom: 10px; padding: 0 11px; border-radius: 7px; background: rgba(98, 217, 149, .09); color: var(--green); font-size: 11px; font-weight: 700; }
.health-banner.down { color: var(--red); background: rgba(255, 119, 119, .09); }
.health-banner.unknown { color: var(--amber); background: rgba(255, 195, 102, .09); }
.health-banner::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.service-list { overflow: hidden; border: 1px solid var(--line); border-radius: 8px; background: var(--panel); }
.service { display: grid; grid-template-columns: 29px minmax(0, 1fr) auto; align-items: center; gap: 10px; min-height: 59px; padding: 10px 11px; }
.service + .service { border-top: 1px solid var(--line); }
.service-icon { display: grid; place-items: center; width: 27px; height: 27px; border-radius: 50%; background: rgba(98, 217, 149, .1); color: var(--green); font-size: 13px; }
.service-icon.down { background: rgba(255, 119, 119, .1); color: var(--red); }
.service-icon.unknown { background: rgba(255, 195, 102, .1); color: var(--amber); }
.service-copy { min-width: 0; }
.service-copy strong { display: block; overflow: hidden; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.service-copy small { display: block; overflow: hidden; margin-top: 3px; color: var(--muted); font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.service-state { color: var(--green); font-size: 9px; font-weight: 700; text-align: right; white-space: nowrap; }
.service-state.down { color: var(--red); }
.service-state.unknown { color: var(--amber); }
.version { color: var(--muted); font: 9px ui-monospace, SFMono-Regular, Consolas, monospace; }
.routes { margin-top: 9px; border: 1px solid var(--line); border-radius: 8px; background: var(--panel); }
.routes summary { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 42px; padding: 0 11px; cursor: pointer; font-size: 10px; font-weight: 700; }
.routes summary span { color: var(--muted); font-size: 9px; font-weight: 500; }
.route-list { max-height: 270px; overflow: auto; padding: 0 11px 7px; }
.route { display: grid; grid-template-columns: 7px minmax(80px, .8fr) minmax(0, 1fr); align-items: center; gap: 8px; min-height: 29px; border-top: 1px solid var(--line); color: var(--muted); font-size: 9px; }
.route-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--green); }
.route-dot.down { background: var(--red); }
.route code { color: var(--text); font: 9px ui-monospace, SFMono-Regular, Consolas, monospace; overflow-wrap: anywhere; }
.route-detail { overflow: hidden; text-align: right; text-overflow: ellipsis; white-space: nowrap; }
.note { display: flex; align-items: start; gap: 10px; margin-top: 18px; padding: 14px; border: 1px solid var(--line); border-radius: 9px; color: var(--muted); }
.note-icon { display: grid; place-items: center; flex: none; width: 17px; height: 17px; border: 1px solid #626a72; border-radius: 50%; color: #b6bcc2; font: 500 11px Georgia, serif; }
.note p { margin: 0; font-size: 10px; line-height: 1.6; }
.footer { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: 32px; padding: 17px 0 24px; border-top: 1px solid var(--line); color: var(--muted-2); font-size: 10px; }
.footer a { color: var(--muted); text-decoration: none; }
.footer a:hover { color: var(--text); }
.loading-card { display: grid; gap: 10px; }
.skeleton { display: block; border-radius: 6px; background: linear-gradient(90deg, #17191b, #202326, #17191b); background-size: 200% 100%; animation: shimmer 1.5s ease-in-out infinite; }
.skeleton-heading { width: 45%; height: 42px; margin-bottom: 8px; }
.skeleton-row { width: 100%; height: 48px; }
@keyframes shimmer { to { background-position: -200% 0; } }
.error { padding: 28px; text-align: center; color: var(--muted); font-size: 12px; }

@media (max-width: 760px) {
  .environments { grid-template-columns: 1fr; }
  .intro { align-items: start; flex-direction: column; padding-top: 40px; }
  .refresh-button { align-self: start; }
}
@media (max-width: 480px) {
  .shell { width: min(100% - 28px, 980px); }
  .masthead { height: 64px; }
  .masthead-label { font-size: 9px; }
  .intro { gap: 18px; padding-top: 34px; }
  h1 { font-size: 33px; }
  .lede { font-size: 13px; line-height: 1.6; }
  .overall { grid-template-columns: auto minmax(0, 1fr); padding: 15px; }
  .checked-at { grid-column: 2; }
  .environment-card { padding: 12px; }
  .service { grid-template-columns: 27px minmax(0, 1fr); }
  .service-state { grid-column: 2; text-align: left; }
  .footer { align-items: start; flex-direction: column; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: 2s !important; transition-duration: .01ms !important; }
}
