/* BittenBytes public service shell.
   Source of truth: PUBLIC.md in the docs-and-tooling repository.
   Values are the Tailwind ramps as remapped there, written out literally
   because this page is static and carries no Tailwind build. */

@font-face {
  font-family: 'Poiret One';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/poiret-one-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Poiret One';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/poiret-one-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Urbanist';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('/fonts/urbanist-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Urbanist';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('/fonts/urbanist-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 100 800;
  font-display: swap;
  src: url('/fonts/jetbrains-mono-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'JetBrains Mono';
  font-style: normal;
  font-weight: 100 800;
  font-display: swap;
  src: url('/fonts/jetbrains-mono-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --primary-300: #5AA68F;
  --primary-500: #3D7A6A;
  --primary-600: #387061;
  --primary-700: #326658;
  --primary-800: #2D5C4F;

  --gray-50:  #F5F4F0;
  --gray-100: #F5F5F3;
  --gray-200: #ECEAE4;
  --gray-300: #D8D6D0;
  --gray-400: #B8B5AE;
  --gray-500: #8A8680;
  --gray-600: #49453F;
  --gray-700: #363330;
  --gray-800: #2C2A27;
  --gray-900: #1F1D1C;
  --gray-950: #161411;

  --amber: #C8A96E;
  --amber-deep: #816026;
  --red: #CF8174;
  --red-deep: #8E4034;

  --font-sans: 'Urbanist', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, 'SFMono-Regular', Menlo, monospace;
  --font-display: 'Poiret One', sans-serif;

  --page-bg: var(--gray-50);
  --surface: #FFFFFF;
  --text: #2A2824;
  --muted: var(--gray-600);
  --line: var(--gray-300);
  --ok: var(--primary-600);
  --warn: var(--amber-deep);
  --bad: var(--red-deep);
  --nodata: var(--gray-300);

  /* 17px at phone widths, 18px from roughly 900px up */
  font-size: clamp(1.0625rem, 1.01rem + 0.28vw, 1.125rem);
}

.dark {
  --page-bg: var(--gray-950);
  --surface: var(--gray-900);
  --text: #F5F5F3;
  --muted: var(--gray-400);
  --line: var(--gray-700);
  --ok: var(--primary-300);
  --warn: var(--amber);
  --bad: var(--red);
  --nodata: var(--gray-600);
}

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

body {
  margin: 0;
  font-family: var(--font-sans);
  font-weight: 400;
  line-height: 1.6;
  background: var(--page-bg);
  color: var(--text);
}

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 400;
  font-synthesis: none;
  margin: 0;
}

.mono {
  font-family: var(--font-mono);
  font-weight: 400;
}

.skip {
  position: absolute;
  left: -9999px;
}
.skip:focus {
  left: 1rem;
  top: 0.5rem;
  z-index: 60;
  padding: 0.5rem 0.875rem;
  border-radius: 0.5rem;
  background: var(--amber);
  color: #2A2824;
  font-weight: 600;
}

/* --- Nav: charcoal in both themes, does not invert --- */

.nav {
  background: var(--gray-950);
  border-bottom: 1px solid rgba(245, 245, 243, 0.1);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  max-width: 1920px;
  margin: 0 auto;
  padding: 0.75rem 1.5rem;
}
.nav a.brand {
  display: flex;
  align-items: center;
  opacity: 1;
  transition: opacity 300ms ease-in-out;
}
.nav a.brand:hover { opacity: 0.7; }
.site-logo { min-height: 3.25em; height: 3.25em; width: auto; }

.nav-links {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.25rem;
}
.nav-links a {
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--gray-200);
  text-decoration: none;
}
.nav-links a:hover { background: var(--primary-600); color: #fff; }

.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  margin-left: 0.5rem;
  border: 0;
  border-radius: 0.5rem;
  background: transparent;
  color: var(--gray-200);
  cursor: pointer;
}
.theme-toggle:hover { background: var(--primary-600); color: #fff; }
.theme-toggle svg { width: 1.125rem; height: 1.125rem; }
.dark .theme-toggle .icon-moon,
html:not(.dark) .theme-toggle .icon-sun { display: none; }

a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--primary-300);
  outline-offset: 2px;
}

/* --- Page header band: the one place a public page shouts --- */

.band {
  background: var(--primary-600);
  padding: 3rem 1.5rem;
  text-align: center;
}
.band h1 {
  font-size: clamp(2.25rem, 1.6rem + 2.4vw, 3rem);
  color: #fff;
  line-height: 1.1;
}

/* --- Content --- */

main {
  max-width: 64rem;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 4rem;
}

.overall {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.25rem;
  margin-bottom: 2rem;
  border-radius: 1rem;
  background: var(--surface);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1), 0 1px 2px rgba(0, 0, 0, 0.06);
  font-size: 1.0625rem;
  font-weight: 600;
}
.dot {
  width: 0.625rem;
  height: 0.625rem;
  border-radius: 9999px;
  flex: none;
}
.dot.operational { background: var(--ok); }
.dot.degraded { background: var(--warn); }
.dot.down { background: var(--bad); }
.dot.unknown { background: var(--nodata); }

/* --- Notices --- */

.notices {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 2rem;
}
.notice {
  background: var(--surface);
  border-radius: 1rem;
  padding: 1.25rem 1.5rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1), 0 1px 2px rgba(0, 0, 0, 0.06);
  border-left: 4px solid var(--line);
}
.notice.info    { border-left-color: var(--ok); }
.notice.warning { border-left-color: var(--warn); }
.notice.outage  { border-left-color: var(--bad); }
.notice h3 {
  font-family: var(--font-sans);
  font-size: 0.9375rem;
  font-weight: 600;
  margin-bottom: 0.25rem;
}
.notice-date {
  display: block;
  font-size: 0.8125rem;
  color: var(--muted);
  margin-bottom: 0.5rem;
}

h2.group {
  margin: 2rem 0 0.75rem;
  font-size: 1.5rem;
  color: var(--text);
}

.card {
  background: var(--surface);
  border-radius: 1rem;
  padding: 1.25rem 1.5rem;
  margin-bottom: 0.75rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1), 0 1px 2px rgba(0, 0, 0, 0.06);
  transition: box-shadow 150ms ease;
}
.card:hover {
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
}

.card-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
}
.name {
  font-family: var(--font-mono);
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--text);
}
.state {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  font-weight: 600;
}
.state.operational { color: var(--ok); }
.state.degraded { color: var(--warn); }
.state.down { color: var(--bad); }
.state.unknown { color: var(--muted); }
.state .uptime {
  color: var(--muted);
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}

.probes {
  display: flex;
  flex-wrap: wrap;
  gap: 0.375rem;
  margin-top: 0.75rem;
}
.pill {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.1875rem 0.625rem;
  border: 1px solid var(--line);
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.pill .mono { font-size: 0.75rem; }
.pill.up { border-color: var(--ok); color: var(--ok); }
.pill.down { border-color: var(--bad); color: var(--bad); }
.pill.warn { border-color: var(--warn); color: var(--warn); }

.bars {
  display: flex;
  gap: 2px;
  height: 2rem;
  margin-top: 1rem;
}
.bar {
  flex: 1 1 0;
  min-width: 2px;
  border-radius: 2px;
}
.bar.ok { background: var(--ok); }
.bar.warn { background: var(--warn); }
.bar.bad { background: var(--bad); }
.bar.none { background: var(--nodata); }

.scale {
  display: flex;
  justify-content: space-between;
  margin-top: 0.375rem;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--muted);
}

.footer {
  background: var(--gray-900);
  color: var(--gray-400);
  padding: 2rem 1.5rem;
  text-align: center;
  font-size: 0.875rem;
}
.footer a { color: var(--gray-400); text-decoration: underline; }
.footer a:hover { color: var(--gray-300); }
.footer .generated { display: block; margin-top: 0.5rem; }

@media (max-width: 639px) {
  .nav-inner { padding: 0.625rem 1rem; }
  .site-logo { min-height: 2.5em; height: 2.5em; }
  .nav-links a { padding: 0.375rem 0.625rem; font-size: 13px; }
  main { padding: 1.75rem 1rem 3rem; }
  .card { padding: 1rem 1.125rem; }
  .pill { font-size: 13px; }
  .scale, .footer { font-size: 13px; }

  /* 90 bars plus their gaps do not fit a phone at the desktop rhythm. */
  .bars { gap: 1px; height: 1.75rem; }
  .bar { min-width: 1px; border-radius: 1px; }
}
