:root {
  color-scheme: light dark;
  --bg: #fff;
  --ink: #202124;
  --muted: #5f6368;
  --line: #dadce0;
  --header: rgba(0, 0, 0, 0.04);
  --primary: #1a73e8;
  --primary-ink: #174ea6;
  --fastest: #09af00;
  --focus: #174ea6;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial,
    sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #121416;
    --ink: #e8eaed;
    --muted: #9aa0a6;
    --line: #3c4043;
    --header: rgba(255, 255, 255, 0.06);
    --primary: #8ab4f8;
    --primary-ink: #d2e3fc;
    --fastest: #81c995;
    --focus: #8ab4f8;
  }
}

* {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.5;
}

.page {
  width: min(100%, 44rem);
  margin-inline: auto;
  padding-inline: 1rem;
}

.top {
  border-bottom: 1px solid var(--line);
}

.bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  padding: 1rem 0;
}

.bar h1 {
  margin: 0;
  font-size: clamp(1.5rem, 1.2rem + 1vw, 2rem);
  font-weight: 650;
  letter-spacing: -0.02em;
  line-height: 1.15;
}

.subtitle {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  padding: 1.25rem 0;
}

.subtitle p {
  margin: 0;
  font-size: 1.2rem;
  font-weight: 400;
  line-height: 1.3;
}

.status {
  margin: 0.75rem auto;
  color: var(--muted);
  font-size: 0.95rem;
}

.timing-note {
  color: var(--primary-ink);
}

button {
  font: inherit;
  color: var(--primary);
  background: transparent;
  border: 0;
  padding: 0.35rem 0.15rem;
  cursor: pointer;
}

button:hover {
  text-decoration: underline;
}

button:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 3px;
}

#stopstart {
  font-size: 1.2rem;
}

.table-wrap {
  padding: 0.5rem 0 3rem;
  overflow-x: auto;
}

table {
  width: 100%;
  table-layout: fixed;
  border-collapse: collapse;
}

caption {
  text-align: start;
}

thead th {
  background: var(--header);
  font-weight: 550;
  text-align: start;
  overflow-wrap: anywhere;
}

thead th:nth-child(3) {
  width: 9.75rem;
  white-space: nowrap;
}

th,
td {
  padding: 0.35rem 1rem;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
  text-align: start;
}

tbody th {
  font-weight: 550;
}

thead th button {
  color: inherit;
  font-weight: inherit;
  padding: 0;
}

th[aria-sort="ascending"] button::after {
  content: " \2193";
  color: var(--muted);
}

th[aria-sort="descending"] button::after {
  content: " \2191";
  color: var(--muted);
}

.region-id {
  font-size: 0.92em;
  overflow-wrap: anywhere;
}

td.num {
  font-variant-numeric: tabular-nums;
  text-align: end;
  white-space: nowrap;
}

tbody tr.fastest-region th {
  border-left: 4px solid var(--fastest);
}

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

.noscript {
  padding: 1rem 0;
}

dialog {
  width: min(40rem, calc(100% - 2rem));
  padding: 1.25rem 1.5rem 1.5rem;
  border: 1px solid var(--line);
  background: var(--bg);
  color: var(--ink);
}

dialog::backdrop {
  background: rgba(0, 0, 0, 0.4);
}

dialog h2 {
  margin: 0 0 0.75rem;
  font-size: 1.35rem;
  font-weight: 600;
  line-height: 1.2;
}

.prose {
  max-width: 65ch;
}

.prose p {
  margin: 0 0 1rem;
}

.prose a {
  color: var(--primary);
  text-decoration: underline;
}

.prose code {
  font-size: 0.92em;
  overflow-wrap: anywhere;
}

dialog form {
  margin-top: 0.5rem;
}

@media (max-width: 40rem) {
  th,
  td {
    padding: 0.35rem 0.4rem;
  }

  .subtitle p,
  #stopstart {
    font-size: 1.05rem;
  }
}
