/* Aurix Status v3. Cinematic style to match aurix.host. Mobile first, rem based (scales on TVs).
   No inline styles anywhere: the page has a strict Content Security Policy. */

@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("inter-var-latin.woff2") format("woff2");
}

:root {
  --bg: #0a0e19;
  --ink: #070a12;
  --card: rgba(13, 19, 33, 0.86);
  --card-solid: #0f1626;
  --card-2: #141b2d;
  --card-3: #1a2338;
  --border: rgba(120, 150, 210, 0.12);
  --border-strong: rgba(120, 150, 210, 0.22);
  --primary: #3b82f6;
  --primary-text: #60a5fa;
  --accent: #22d3ee;
  --gold: #f5b82e;
  --green: #22c55e;
  --red: #ef4444;
  --orange: #f97316;
  --grey: #64748b;
  --discord: #4752c4;
  --discord-hover: #3c45a5;
  --text: #e7ebf3;
  --text-2: #b4bccd;
  --text-3: #7d879e;
  --nodata: #1f2738;
  --radius: 10px;
  --radius-lg: 14px;
  --container: 1200px;
  --gutter: clamp(16px, 4vw, 40px);
  --header-h: 64px;
  --jump-h: 56px;
  --font: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  --tint: var(--grey);
  --tone: 100, 116, 139;
  color-scheme: dark;
}

/* --tint is a colour, --tone the same colour as "r, g, b" for rgba(). */
.state-up, .hx-up, .chapter-up, .pc-up, .mon-up, .jump-up, .tk-up { --tint: var(--green); --tone: 34, 197, 94; }
.state-degraded, .hx-degraded, .chapter-degraded, .pc-degraded, .mon-degraded, .jump-degraded, .tk-degraded { --tint: var(--gold); --tone: 245, 184, 46; }
.state-partial, .hx-partial, .chapter-partial, .pc-partial, .mon-partial, .jump-partial, .tk-partial { --tint: var(--orange); --tone: 249, 115, 22; }
.state-down, .hx-down, .chapter-down, .pc-down, .mon-down, .jump-down, .tk-down { --tint: var(--red); --tone: 239, 68, 68; }
.state-maintenance, .hx-maintenance, .chapter-maintenance, .pc-maintenance, .mon-maintenance, .jump-maintenance, .tk-maintenance { --tint: var(--accent); --tone: 34, 211, 238; }
.state-unknown, .hx-unknown, .chapter-unknown, .pc-unknown, .mon-unknown, .jump-unknown, .tk-unknown { --tint: var(--grey); --tone: 100, 116, 139; }

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  background: var(--bg);
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + var(--jump-h) + 16px);
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}

h1, h2, h3, p, ul, ol, dl, dd, figure { margin: 0; }
h1, h2, h3 { font-weight: 800; letter-spacing: -0.02em; line-height: 1.1; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }
img, svg { display: block; }
.icon, .flag { flex: none; }
.flag { border-radius: 3px; box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.14); }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }
main:focus { outline: none; }

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  top: -64px;
  left: 16px;
  z-index: 100;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 16px;
  border-radius: var(--radius);
  background: var(--primary);
  color: #fff;
  font-weight: 600;
}
.skip-link:focus { top: 8px; }

.container {
  width: 100%;
  max-width: calc(var(--container) + 2 * var(--gutter));
  margin-inline: auto;
  padding-inline: max(var(--gutter), env(safe-area-inset-left)) max(var(--gutter), env(safe-area-inset-right));
}

.muted { color: var(--text-3); }

.kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--text-3);
}

/* -------------------------------------------------------------- header */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  padding-top: env(safe-area-inset-top);
  background: rgba(7, 10, 18, 0.78);
  border-bottom: 1px solid var(--border);
}
@supports (backdrop-filter: blur(4px)) {
  .site-header { background: rgba(7, 10, 18, 0.6); backdrop-filter: blur(16px) saturate(1.4); -webkit-backdrop-filter: blur(16px) saturate(1.4); }
}

.header-inner { display: flex; align-items: center; gap: 12px; min-height: var(--header-h); }
.brand { display: inline-flex; align-items: center; gap: 12px; min-height: 44px; }
.brand img { width: auto; height: 2rem; }
.brand-tag {
  padding: 4px 10px;
  border: 1px solid rgba(var(--tone), 0.45);
  border-radius: 999px;
  background: rgba(var(--tone), 0.12);
  color: #fff;
  font-size: 0.6875rem;
  font-weight: 800;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.header-actions { display: flex; gap: 8px; margin-left: auto; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 1rem;
  border: 1px solid transparent;
  border-radius: var(--radius);
  font: inherit;
  font-size: 0.9375rem;
  font-weight: 600;
  white-space: nowrap;
  transition: background-color 0.15s, border-color 0.15s, transform 0.15s var(--ease);
}
.btn:active { transform: translateY(1px); }
.btn-ghost { border-color: var(--border-strong); background: rgba(20, 27, 45, 0.6); }
.btn-ghost:hover { background: var(--card-3); }
.btn-discord { background: var(--discord); color: #fff; }
.btn-discord:hover { background: var(--discord-hover); }

/* -------------------------------------------------------------- hero */

main { flex: 1; }

.hx {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding-block: clamp(40px, 7vw, 104px) clamp(36px, 6vw, 88px);
}

.hx-bg { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.hx-glow {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(55% 60% at 76% 46%, rgba(var(--tone), 0.26), transparent 70%),
    radial-gradient(45% 45% at 6% 100%, rgba(59, 130, 246, 0.14), transparent 70%),
    linear-gradient(180deg, transparent 70%, var(--bg));
}
.hx-grid {
  position: absolute;
  inset: 0;
  background-image: linear-gradient(rgba(var(--tone), 0.08) 1px, transparent 1px), linear-gradient(90deg, rgba(var(--tone), 0.08) 1px, transparent 1px);
  background-size: 48px 48px;
  -webkit-mask-image: radial-gradient(60% 70% at 70% 40%, #000, transparent 75%);
  mask-image: radial-gradient(60% 70% at 70% 40%, #000, transparent 75%);
}
.hx-ghost {
  position: absolute;
  left: 50%;
  top: 52%;
  font-size: clamp(6rem, 24vw, 26rem);
  font-weight: 900;
  line-height: 0.8;
  letter-spacing: -0.06em;
  white-space: nowrap;
  color: transparent;
  -webkit-text-stroke: 1.5px rgba(var(--tone), 0.14);
  transform: translate(-50%, -50%);
  user-select: none;
}

.hx-inner { display: grid; gap: clamp(24px, 4vw, 48px); align-items: center; }
.hx-copy { display: grid; gap: 1.25rem; min-width: 0; }

.hx-eyebrow { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; font-size: 0.75rem; font-weight: 700; letter-spacing: 0.2em; text-transform: uppercase; color: rgba(var(--tone), 1); }
.hx-eyebrow time { letter-spacing: 0.08em; }
.hx-sep { width: 24px; height: 2px; background: currentColor; opacity: 0.6; }

.live-dot { position: relative; width: 10px; height: 10px; border-radius: 50%; background: var(--tint); }
.live-dot::after { content: ""; position: absolute; inset: 0; border-radius: 50%; background: var(--tint); animation: pulse 2s ease-out infinite; }
@keyframes pulse { 0% { transform: scale(1); opacity: 0.7; } 100% { transform: scale(3); opacity: 0; } }

.hx h1 { font-size: clamp(3rem, 10vw, 7.5rem); font-weight: 900; line-height: 0.9; letter-spacing: -0.055em; }
.hx-line { display: block; padding-bottom: 0.06em; background: linear-gradient(180deg, #fff 30%, #c7d2e6); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hx-accent { background: linear-gradient(100deg, #fff -20%, rgba(var(--tone), 1) 55%, var(--accent) 140%); -webkit-background-clip: text; background-clip: text; }
.state-up .hx-accent { background-image: linear-gradient(100deg, #fff -30%, var(--green) 45%, var(--accent) 130%); }

.hx-long h1 { font-size: clamp(2.5rem, 8.4vw, 6rem); }
.hx-lead { max-width: 34rem; font-size: clamp(1rem, 1.6vw, 1.1875rem); color: var(--text-2); }

.hx-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px; margin-top: 0.5rem; overflow: hidden; border: 1px solid var(--border); border-radius: var(--radius-lg); background: var(--border); }
.hx-stats li { display: grid; gap: 2px; padding: 14px 16px; background: rgba(7, 10, 18, 0.82); }
.hx-stats b { font-size: clamp(1.5rem, 3vw, 2.25rem); font-weight: 800; line-height: 1.1; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.hx-stats small { font-size: 0.55em; color: var(--text-3); font-weight: 700; }
.hx-stats span { font-size: 0.75rem; font-weight: 600; letter-spacing: 0.04em; color: var(--text-3); }

.hx-visual { position: relative; display: grid; place-items: center; min-height: 0; }
.hx-ring { position: absolute; left: 50%; bottom: 4%; width: 80%; height: 22%; border-radius: 50%; background: radial-gradient(closest-side, rgba(var(--tone), 0.35), transparent); transform: translateX(-50%); filter: blur(6px); }
.hx-scene { position: relative; width: auto; height: auto; max-width: min(100%, 26rem); max-height: 15rem; filter: drop-shadow(0 30px 50px rgba(0, 0, 0, 0.55)); animation: float 7s ease-in-out infinite; }
@keyframes float { 50% { transform: translateY(-10px); } }

/* entrance on first load only (the live refresh adds .is-refreshed) */
.hx-copy > * { animation: rise 0.8s var(--ease) both; }
.hx-copy > :nth-child(2) { animation-delay: 0.06s; }
.hx-copy > :nth-child(3) { animation-delay: 0.14s; }
.hx-copy > :nth-child(4) { animation-delay: 0.22s; }
.hx-visual { animation: fade 1.2s var(--ease) both; }
.is-refreshed .hx-copy > *, .is-refreshed .hx-visual { animation: none; }
@keyframes rise { from { opacity: 0; transform: translateY(18px); } }
@keyframes fade { from { opacity: 0; transform: scale(0.96); } }

/* -------------------------------------------------------------- ticker */

.ticker {
  overflow: hidden;
  border-block: 1px solid var(--border);
  background: var(--ink);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.ticker-track { display: flex; width: max-content; animation: ticker 40s linear infinite; }
.ticker-track li {
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  padding: 16px 0 16px 1.4em;
  font-size: clamp(1.25rem, 3vw, 2.25rem);
  font-weight: 850;
  letter-spacing: -0.03em;
  text-transform: uppercase;
  white-space: nowrap;
  color: #fff;
}
.ticker-track li:nth-child(even) { color: transparent; -webkit-text-stroke: 1px rgba(180, 200, 240, 0.4); }
.ticker-track li span { color: var(--tint); -webkit-text-stroke: 0; }
.ticker-track li::after { content: ""; width: 0.28em; height: 0.28em; margin-left: 0.9em; border-radius: 2px; background: var(--primary); transform: rotate(45deg); }
@keyframes ticker { to { transform: translateX(-50%); } }

/* -------------------------------------------------------------- jump bar */

.jump {
  position: sticky;
  top: calc(var(--header-h) + env(safe-area-inset-top));
  z-index: 40;
  border-bottom: 1px solid var(--border);
  background: rgba(10, 14, 25, 0.88);
}
@supports (backdrop-filter: blur(4px)) {
  .jump { background: rgba(10, 14, 25, 0.66); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
}
.jump-list { display: flex; gap: 6px; min-height: var(--jump-h); align-items: center; overflow-x: auto; scrollbar-width: none; }
.jump-list::-webkit-scrollbar { display: none; }
.jump a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 14px;
  border-radius: 999px;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-2);
  white-space: nowrap;
  transition: background-color 0.15s, color 0.15s;
}
.jump a:hover { background: var(--card-2); color: #fff; }
.jump .dot { background: var(--tint); }
.jump .dot-plain { background: var(--text-3); }

/* -------------------------------------------------------------- layout blocks */

.stack { display: grid; gap: clamp(56px, 8vw, 112px); padding-block: clamp(32px, 5vw, 64px) clamp(64px, 9vw, 128px); }

.block { display: grid; gap: 1.5rem; }
.block-head { display: grid; gap: 8px; }
.block-head h2, .chapter-title h2 { font-size: clamp(2rem, 5vw, 3.5rem); font-weight: 900; letter-spacing: -0.045em; line-height: 1; }

.dot { width: 8px; height: 8px; flex: none; border-radius: 50%; background: currentColor; }

/* -------------------------------------------------------------- alerts (incidents, maintenance, notices) */

.alerts { display: grid; gap: 14px; }
.alert {
  --tint: var(--gold);
  --tone: 245, 184, 46;
  position: relative;
  overflow: hidden;
  padding: clamp(18px, 3vw, 28px);
  padding-left: clamp(22px, 3.4vw, 34px);
  border: 1px solid rgba(var(--tone), 0.4);
  border-radius: var(--radius-lg);
  background: linear-gradient(110deg, rgba(var(--tone), 0.16), rgba(var(--tone), 0.03) 60%), var(--card-solid);
}
.alert::before { content: ""; position: absolute; inset: 0 auto 0 0; width: 4px; background: var(--tint); }
.event-degraded { --tint: var(--gold); --tone: 245, 184, 46; }
.event-partial { --tint: var(--orange); --tone: 249, 115, 22; }
.event-down { --tint: var(--red); --tone: 239, 68, 68; }
.event-info { --tint: var(--primary); --tone: 59, 130, 246; }
.event-maintenance { --tint: var(--accent); --tone: 34, 211, 238; }

.alert-head { display: flex; gap: 16px; }
.alert-icon { display: grid; place-items: center; width: 46px; height: 46px; flex: none; border-radius: 12px; background: rgba(var(--tone), 0.16); color: var(--tint); }
.alert .kicker { color: var(--tint); }
.alert h2 { margin: 6px 0; font-size: clamp(1.25rem, 2.4vw, 1.625rem); letter-spacing: -0.025em; }
.alert p { color: var(--text-2); font-size: 0.9375rem; }
.alert .muted { color: var(--text-3); font-size: 0.8125rem; margin-top: 4px; }
.is-live .alert-icon { animation: glow 2.4s ease-in-out infinite; }
@keyframes glow { 50% { box-shadow: 0 0 0 6px rgba(var(--tone), 0.12); } }

.timeline { display: grid; gap: 14px; margin: 18px 0 0 22px; padding-left: 22px; border-left: 2px solid var(--border-strong); }
.timeline li { position: relative; }
.timeline li::before { content: ""; position: absolute; left: -29px; top: 6px; width: 12px; height: 12px; border-radius: 50%; background: var(--card-solid); border: 2px solid var(--tint, var(--primary)); }
.timeline li:first-child::before { background: var(--tint, var(--primary)); }
.tl-head { display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: baseline; font-size: 0.875rem; }
.tl-head .muted { font-size: 0.8125rem; }
.timeline p + p { margin-top: 2px; color: var(--text-2); font-size: 0.9375rem; }

/* -------------------------------------------------------------- location postcards */

.pcs { display: grid; gap: 16px; grid-template-columns: minmax(0, 1fr); }

.pc {
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: #0b1120;
  transition: border-color 0.2s, transform 0.25s var(--ease), box-shadow 0.25s;
}
.pc:hover { border-color: rgba(var(--tone), 0.5); transform: translateY(-3px); box-shadow: 0 24px 50px -24px rgba(var(--tone), 0.45); }
.pc-art {
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: 2 / 1;
  background: radial-gradient(65% 70% at 50% 72%, rgba(var(--tone), 0.3), transparent 72%), linear-gradient(180deg, #0a1124, #0b1120);
}
.pc-scene { position: absolute; inset: 8% 0 4%; width: 100%; height: 88%; margin: auto; object-fit: contain; filter: drop-shadow(0 18px 26px rgba(0, 0, 0, 0.5)); transition: transform 0.5s var(--ease); }
.pc:hover .pc-scene { transform: translateY(-6px) scale(1.03); }
.pc-flag { position: absolute; top: 14px; left: 14px; }
.pc-body { display: grid; gap: 6px; padding: 18px 20px 20px; flex: 1; align-content: start; }
.pc-name { font-size: clamp(2rem, 3.4vw, 2.75rem); font-weight: 900; letter-spacing: -0.05em; line-height: 1; }
.pc-state { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; color: var(--tint); }
.pc-state .dot { width: 9px; height: 9px; background: var(--tint); box-shadow: 0 0 0 4px rgba(var(--tone), 0.18); }
.pc-facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; margin-block: 10px 4px; overflow: hidden; border: 1px solid var(--border); border-radius: var(--radius); background: var(--border); }
.pc-facts:empty { display: none; }
.pc-facts > span { display: grid; padding: 8px 12px; background: #0b1120; }
.pc-facts small { font-size: 0.6875rem; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; color: var(--text-3); }
.pc-facts b { font-size: 1.125rem; font-variant-numeric: tabular-nums; }
.pc-hw { display: inline-flex; align-items: center; gap: 6px; font-size: 0.8125rem; color: var(--text-2); }
.pc-hw .icon { color: var(--text-3); }
.pc-go { display: inline-flex; align-items: center; gap: 4px; margin-top: 6px; font-size: 0.875rem; font-weight: 700; color: var(--primary-text); }
.pc:hover .pc-go .icon { transform: translateX(3px); }
.pc-go .icon { transition: transform 0.2s var(--ease); }

/* -------------------------------------------------------------- chapters (one per section) */

.chapter { display: grid; gap: 1.5rem; }
.chapter-head { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: end; gap: 6px 18px; padding-bottom: 18px; border-bottom: 1px solid var(--border); }
.chapter-num {
  font-size: clamp(3.25rem, 9vw, 6.5rem);
  font-weight: 900;
  line-height: 0.78;
  letter-spacing: -0.06em;
  color: transparent;
  background: linear-gradient(180deg, rgba(var(--tone), 0.85), rgba(59, 130, 246, 0.08) 95%);
  -webkit-background-clip: text;
  background-clip: text;
  padding-bottom: 0.04em;
  font-variant-numeric: tabular-nums;
}
.chapter-title { display: grid; gap: 8px; min-width: 0; }
.chapter-title h2 { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.chapter-title .flag { width: 2.1rem; height: auto; }
.chapter-head .pill { margin-bottom: 4px; }

.mons { display: grid; gap: 16px; grid-template-columns: minmax(0, 1fr); }

.mon {
  position: relative;
  display: grid;
  gap: 16px;
  align-content: start;
  min-width: 0;
  padding: clamp(18px, 2.4vw, 26px);
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, rgba(var(--tone), 0.07), transparent 120px), var(--card);
  container-type: inline-size;
}
.mon::before { content: ""; position: absolute; inset: 0 0 auto; height: 2px; background: linear-gradient(90deg, var(--tint), transparent 70%); opacity: 0.8; }
.mon-down, .mon-degraded, .mon-partial { border-color: rgba(var(--tone), 0.4); }

.mon-head { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: start; gap: 14px; }
.mon-icon { display: grid; place-items: center; width: 40px; height: 40px; border-radius: var(--radius); background: rgba(var(--tone), 0.14); color: var(--tint); }
.mon-name h3 { font-size: 1.125rem; letter-spacing: -0.02em; }
.mon-name p { font-size: 0.875rem; overflow-wrap: anywhere; }
.mon-state { display: grid; justify-items: end; gap: 6px; }
.mon-meta { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 4px 8px; font-size: 0.8125rem; color: var(--text-3); font-variant-numeric: tabular-nums; }
.mon-meta span + span::before { content: "·"; margin-right: 8px; }

.mon-message { display: flex; gap: 10px; padding: 10px 12px; border-radius: var(--radius); font-size: 0.875rem; color: var(--text-2); background: rgba(var(--tone), 0.12); }
.mon-message .icon { margin-top: 2px; color: var(--tint); }

.pill {
  --tint: var(--grey);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 12px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--tint) 14%, transparent);
  border: 1px solid color-mix(in srgb, var(--tint) 32%, transparent);
  color: color-mix(in srgb, var(--tint) 70%, white);
  font-size: 0.8125rem;
  font-weight: 700;
  white-space: nowrap;
}
.pill .dot { color: var(--tint); }
.pill-up { --tint: var(--green); }
.pill-degraded { --tint: var(--gold); }
.pill-partial { --tint: var(--orange); }
.pill-down { --tint: var(--red); }
.pill-maintenance { --tint: var(--accent); }

.tag { display: inline-block; padding: 1px 8px; border-radius: 999px; background: var(--card-3); color: var(--text-2); font-size: 0.75rem; font-weight: 600; vertical-align: 1px; }

.metrics { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.meter-head { display: flex; justify-content: space-between; gap: 8px; margin-bottom: 6px; font-size: 0.8125rem; color: var(--text-3); }
.meter-head strong { font-weight: 600; color: var(--text-2); font-variant-numeric: tabular-nums; text-align: right; }
.meter-track { height: 8px; overflow: hidden; border-radius: 999px; background: var(--nodata); }
.meter-fill { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--primary), var(--accent)); transition: width 0.6s var(--ease); }
.meter-mid { background: var(--gold); }
.meter-high { background: var(--red); }

.facts { display: flex; flex-wrap: wrap; gap: 4px 24px; font-size: 0.8125rem; }
.facts div { display: flex; gap: 6px; }
.facts dt { color: var(--text-3); }
.facts dd { color: var(--text-2); font-variant-numeric: tabular-nums; }

.chart { display: grid; gap: 6px; }
.chart figcaption { display: flex; justify-content: space-between; gap: 12px; font-size: 0.75rem; color: var(--text-3); }
.chart-stats { display: flex; gap: 12px; font-variant-numeric: tabular-nums; }
.chart-stats b { color: var(--text-2); font-weight: 600; }
.chart-svg { width: 100%; height: 3.5rem; overflow: visible; }
.chart-line { fill: none; stroke: var(--primary-text); stroke-width: 1.8; stroke-linejoin: round; stroke-linecap: round; }
.chart-area { fill: rgba(59, 130, 246, 0.14); }
.chart-base { stroke: rgba(180, 188, 205, 0.25); stroke-width: 1; stroke-dasharray: 3 4; }
.chart-degraded .chart-line, .chart-partial .chart-line { stroke: var(--gold); }
.chart-degraded .chart-area, .chart-partial .chart-area { fill: rgba(245, 184, 46, 0.12); }
.chart-down .chart-line { stroke: var(--red); }
.chart-down .chart-area { fill: rgba(239, 68, 68, 0.12); }

.bars { display: flex; gap: 2px; height: 2rem; }
.bar { flex: 1; min-width: 2px; border-radius: 2px; background: var(--nodata); cursor: default; transition: opacity 0.12s, transform 0.12s; }
.bar-up { background: var(--green); }
.bar-degraded { background: var(--gold); }
.bar-partial { background: var(--orange); }
.bar-down { background: var(--red); }
.bar:hover, .bar.is-active { opacity: 0.65; transform: scaleY(1.12); }

.bars-legend { display: flex; align-items: center; gap: 12px; margin-top: 8px; font-size: 0.75rem; color: var(--text-3); white-space: nowrap; }
.legend-line { flex: 1; height: 1px; background: var(--border); }
.d30 { display: none; }

/* Narrow cards show the last 30 days so each bar stays tappable. */
@container (max-width: 520px) {
  .bar:nth-child(-n + 60) { display: none; }
  .d90 { display: none; }
  .d30 { display: inline; }
  .bars { gap: 3px; }
}
@container (max-width: 440px) {
  .metrics { grid-template-columns: minmax(0, 1fr); }
  .mon-head { grid-template-columns: auto minmax(0, 1fr); }
  .mon-state { grid-column: 1 / -1; justify-items: start; }
  .mon-meta { justify-content: flex-start; }
  .hide-xs { display: none; }
}

/* -------------------------------------------------------------- incidents */

.panel { overflow: hidden; border: 1px solid var(--border); border-radius: var(--radius-lg); background: var(--card); }

.clean { display: flex; align-items: center; gap: 18px; padding: clamp(22px, 4vw, 36px); background: radial-gradient(60% 120% at 0% 50%, rgba(34, 197, 94, 0.14), transparent 70%); }
.clean-icon { display: grid; place-items: center; width: 56px; height: 56px; flex: none; border-radius: 14px; background: rgba(34, 197, 94, 0.16); color: var(--green); }
.clean-title { font-size: clamp(1.5rem, 3vw, 2rem); font-weight: 900; letter-spacing: -0.04em; }

.day { padding: 18px clamp(18px, 2.6vw, 26px); }
.day + .day { border-top: 1px solid var(--border); }
.day h3 { margin-bottom: 12px; font-size: 0.75rem; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase; color: var(--text-3); }
.day ul { display: grid; gap: 14px; }

.incident { --tint: var(--red); display: flex; gap: 12px; font-size: 0.9375rem; }
.incident .dot { width: 10px; height: 10px; margin-top: 7px; color: var(--tint); }
.incident-degraded, .incident-minor { --tint: var(--gold); }
.incident-partial { --tint: var(--orange); }
.incident-maintenance { --tint: var(--accent); }
.incident-info { --tint: var(--primary); }
.incident-closed .dot { opacity: 0.65; }
.incident .muted { font-size: 0.8125rem; }
.incident details { flex: 1; min-width: 0; }
.incident summary { cursor: pointer; list-style: none; }
.incident summary::-webkit-details-marker { display: none; }
.incident summary strong { text-decoration: underline dotted rgba(180, 188, 205, 0.4); text-underline-offset: 3px; }
.incident .timeline { margin-left: 4px; }

/* -------------------------------------------------------------- footer */

.site-footer { position: relative; overflow: hidden; border-top: 1px solid var(--border); background: var(--ink); padding-bottom: env(safe-area-inset-bottom); }
.footer-inner { display: grid; gap: 28px; padding-block: clamp(40px, 6vw, 72px) 28px; }
.footer-slogan {
  font-size: clamp(3rem, 13vw, 10rem);
  font-weight: 900;
  line-height: 0.85;
  letter-spacing: -0.06em;
  color: transparent;
  -webkit-text-stroke: 1.5px rgba(180, 200, 240, 0.22);
}
.footer-slogan span { color: transparent; background: linear-gradient(100deg, var(--primary), var(--accent)); -webkit-background-clip: text; background-clip: text; -webkit-text-stroke: 0; }
.footer-row { display: grid; gap: 6px; padding-top: 20px; border-top: 1px solid var(--border); font-size: 0.8125rem; color: var(--text-2); }
.footer-row a { color: var(--primary-text); }
.footer-row a:hover { text-decoration: underline; }

/* -------------------------------------------------------------- tooltip for the uptime bars */

.tip {
  position: fixed;
  z-index: 60;
  max-width: 260px;
  padding: 6px 10px;
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  background: var(--card-2);
  color: var(--text);
  font-size: 0.8125rem;
  pointer-events: none;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

/* -------------------------------------------------------------- responsive */

/* small phones */
@media (max-width: 420px) {
  .btn-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .btn-ghost { width: 44px; padding: 0; }
  .brand { gap: 8px; }
  .brand img { height: 1.625rem; }
  .brand-tag { padding: 3px 8px; letter-spacing: 0.14em; }
  .refresh-note { display: none; }
  .alert-head { flex-direction: column; gap: 12px; }
}
@media (max-width: 640px) {
  .hide-sm { display: none; }
  .btn-discord { padding: 0; width: 44px; }
  .chapter-head { grid-template-columns: auto minmax(0, 1fr); }
  .chapter-head .pill { grid-column: 1 / -1; justify-self: start; }
}
@media (max-width: 340px) {
  .hx-stats { grid-template-columns: minmax(0, 1fr); }
  .pc-facts { grid-template-columns: minmax(0, 1fr); }
}

/* tablets */
@media (min-width: 640px) {
  .pcs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pcs-1 { grid-template-columns: minmax(0, 1fr); }
  .pc-art { aspect-ratio: 16 / 11; }
  .hx-scene { max-height: 22rem; }
}
@media (min-width: 720px) {
  .hx-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (min-width: 860px) {
  .mons-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .mons-grid > li:last-child:nth-child(odd) { grid-column: 1 / -1; }
}

/* laptops and up: copy left, art right */
@media (min-width: 960px) {
  .hx-inner { grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); }
  .hx-scene { max-width: 100%; max-height: min(64vh, 34rem); }
  .hx-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pcs-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .pcs-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (min-width: 1200px) {
  .hx-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

/* phones on their side and other short screens */
@media (max-height: 520px) and (orientation: landscape) {
  .jump { position: relative; top: 0; }
  html { scroll-padding-top: calc(var(--header-h) + 12px); }
  .hx-inner { grid-template-columns: minmax(0, 1.3fr) minmax(0, 0.7fr); }
  .hx h1 { font-size: clamp(2.5rem, 7vw, 4rem); }
  .hx-scene { max-height: 60vh; }
  .hx-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

/* TVs and big monitors: everything is in rem, so a bigger root size scales the page */
@media (min-width: 1920px) {
  html { font-size: 18px; }
  :root { --container: 1560px; --header-h: 76px; --jump-h: 64px; }
}
@media (min-width: 2560px) {
  html { font-size: 22px; }
  :root { --container: 2000px; --header-h: 92px; --jump-h: 76px; }
  .btn { min-height: 56px; }
}
@media (min-width: 3800px) {
  html { font-size: 30px; }
  :root { --container: 2800px; --header-h: 120px; --jump-h: 100px; }
  .btn { min-height: 76px; }
}
@media (min-width: 1920px) and (hover: none) {
  :focus-visible { outline-width: 4px; outline-offset: 6px; }
}

/* dual-screen and foldable devices (Surface Duo, Galaxy Fold): keep content off the hinge */
@media (horizontal-viewport-segments: 2) {
  .hx-inner, .mons-grid, .pcs {
    grid-template-columns: env(viewport-segment-width 0 0, 1fr) env(viewport-segment-width 1 0, 1fr);
    column-gap: calc(env(viewport-segment-left 1 0, 0px) - env(viewport-segment-right 0 0, 0px));
    padding-inline: 0;
  }
  .stack.container, .hx-inner.container { padding-inline: 0; }
  .hx-copy, .pcs > li:nth-child(odd), .mons-grid > li:nth-child(odd) { padding-inline: var(--gutter) 12px; }
  .hx-visual, .pcs > li:nth-child(even), .mons-grid > li:nth-child(even) { padding-inline: 12px var(--gutter); }
  .chapter-head, .block-head, .alerts, .panel, .mons:not(.mons-grid) { margin-inline: var(--gutter); }
}
@media (vertical-viewport-segments: 2) {
  .hx { min-height: env(viewport-segment-bottom 0 0, 50vh); display: grid; align-items: center; }
  .hx-visual { margin-top: calc(env(viewport-segment-top 0 1, 0px) - env(viewport-segment-bottom 0 0, 0px)); }
}
@media (spanning: single-fold-vertical) {
  .hx-inner { grid-template-columns: env(fold-left, 50vw) calc(100vw - env(fold-right, 50vw)); column-gap: calc(env(fold-right, 50vw) - env(fold-left, 50vw)); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0.01ms !important; animation: none !important; }
  .ticker-track { flex-wrap: wrap; width: auto; }
  .ticker-track li:nth-child(n + 13) { display: none; }
}

@media (forced-colors: active) {
  .bar, .meter-fill, .dot, .live-dot { forced-color-adjust: none; }
  .hx-line, .hx-accent, .footer-slogan span { background: none; color: CanvasText; }
}

@media print {
  .site-header, .ticker, .jump, .hx-bg, .hx-visual, .footer-slogan, .tip { display: none !important; }
  body { background: #fff; color: #000; }
  .hx-line, .hx-accent { background: none; color: #000; }
  .mon, .pc, .panel, .alert { break-inside: avoid; background: #fff; border-color: #bbb; }
}

/* Meter widths (no inline styles: the page has a strict Content Security Policy) */
.w-0 { width: 0%; }
.w-1 { width: 1%; }
.w-2 { width: 2%; }
.w-3 { width: 3%; }
.w-4 { width: 4%; }
.w-5 { width: 5%; }
.w-6 { width: 6%; }
.w-7 { width: 7%; }
.w-8 { width: 8%; }
.w-9 { width: 9%; }
.w-10 { width: 10%; }
.w-11 { width: 11%; }
.w-12 { width: 12%; }
.w-13 { width: 13%; }
.w-14 { width: 14%; }
.w-15 { width: 15%; }
.w-16 { width: 16%; }
.w-17 { width: 17%; }
.w-18 { width: 18%; }
.w-19 { width: 19%; }
.w-20 { width: 20%; }
.w-21 { width: 21%; }
.w-22 { width: 22%; }
.w-23 { width: 23%; }
.w-24 { width: 24%; }
.w-25 { width: 25%; }
.w-26 { width: 26%; }
.w-27 { width: 27%; }
.w-28 { width: 28%; }
.w-29 { width: 29%; }
.w-30 { width: 30%; }
.w-31 { width: 31%; }
.w-32 { width: 32%; }
.w-33 { width: 33%; }
.w-34 { width: 34%; }
.w-35 { width: 35%; }
.w-36 { width: 36%; }
.w-37 { width: 37%; }
.w-38 { width: 38%; }
.w-39 { width: 39%; }
.w-40 { width: 40%; }
.w-41 { width: 41%; }
.w-42 { width: 42%; }
.w-43 { width: 43%; }
.w-44 { width: 44%; }
.w-45 { width: 45%; }
.w-46 { width: 46%; }
.w-47 { width: 47%; }
.w-48 { width: 48%; }
.w-49 { width: 49%; }
.w-50 { width: 50%; }
.w-51 { width: 51%; }
.w-52 { width: 52%; }
.w-53 { width: 53%; }
.w-54 { width: 54%; }
.w-55 { width: 55%; }
.w-56 { width: 56%; }
.w-57 { width: 57%; }
.w-58 { width: 58%; }
.w-59 { width: 59%; }
.w-60 { width: 60%; }
.w-61 { width: 61%; }
.w-62 { width: 62%; }
.w-63 { width: 63%; }
.w-64 { width: 64%; }
.w-65 { width: 65%; }
.w-66 { width: 66%; }
.w-67 { width: 67%; }
.w-68 { width: 68%; }
.w-69 { width: 69%; }
.w-70 { width: 70%; }
.w-71 { width: 71%; }
.w-72 { width: 72%; }
.w-73 { width: 73%; }
.w-74 { width: 74%; }
.w-75 { width: 75%; }
.w-76 { width: 76%; }
.w-77 { width: 77%; }
.w-78 { width: 78%; }
.w-79 { width: 79%; }
.w-80 { width: 80%; }
.w-81 { width: 81%; }
.w-82 { width: 82%; }
.w-83 { width: 83%; }
.w-84 { width: 84%; }
.w-85 { width: 85%; }
.w-86 { width: 86%; }
.w-87 { width: 87%; }
.w-88 { width: 88%; }
.w-89 { width: 89%; }
.w-90 { width: 90%; }
.w-91 { width: 91%; }
.w-92 { width: 92%; }
.w-93 { width: 93%; }
.w-94 { width: 94%; }
.w-95 { width: 95%; }
.w-96 { width: 96%; }
.w-97 { width: 97%; }
.w-98 { width: 98%; }
.w-99 { width: 99%; }
.w-100 { width: 100%; }
