:root {
  color-scheme: light;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #172a35;
  background: #f3f7f7;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  --teal: #1f9e8f;
  --ink: #172a35;
  --muted: #60727d;
  --line: #dfe8e8;
  --surface: #ffffff;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-width: 320px;
  background:
    radial-gradient(ellipse at 8% 0%, rgba(31, 158, 143, 0.09), transparent 34rem),
    #f3f7f7;
}

.status-banner {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-height: 3.25rem;
  padding: 0.7rem max(1.25rem, calc((100vw - 1120px) / 2));
  background: #1f9e8f;
  color: #fff;
  font-size: 0.94rem;
  font-weight: 650;
  letter-spacing: 0.01em;
}

.status-banner p { margin: 0; }

.status-dot {
  width: 0.55rem;
  height: 0.55rem;
  flex: 0 0 auto;
  border-radius: 50%;
  background: #c6f4e9;
  box-shadow: 0 0 0 0.25rem rgba(255, 255, 255, 0.16);
}

.page-shell {
  width: min(100% - 2.5rem, 1120px);
  margin: 0 auto;
  padding: 3.3rem 0 2.5rem;
}

.page-header { margin-bottom: 2.2rem; }

.eyebrow, .section-kicker {
  margin: 0 0 0.55rem;
  color: var(--teal);
  font-size: 0.72rem;
  font-weight: 750;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.eyebrow span { padding: 0 0.35rem; color: #a4b7bd; }

h1 {
  margin: 0;
  color: var(--ink);
  font-size: clamp(2rem, 4vw, 3.15rem);
  font-weight: 760;
  letter-spacing: -0.055em;
  line-height: 1.05;
}

.intro {
  max-width: 46rem;
  margin: 0.9rem 0 0;
  color: #49606b;
  font-size: 1.03rem;
  line-height: 1.6;
}

.feed-updated {
  margin: 0.8rem 0 0;
  color: var(--muted);
  font-size: 0.83rem;
}

.panel {
  overflow: hidden;
  margin: 1.1rem 0;
  border: 1px solid var(--line);
  border-radius: 1rem;
  background: var(--surface);
  box-shadow: 0 12px 32px rgba(23, 42, 53, 0.055);
}

.incidents-panel { padding: 1.6rem 1.65rem 1.35rem; }
.board-panel { padding: 1.5rem 1.65rem 1.6rem; }

.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.15rem;
}

.section-kicker { margin-bottom: 0.3rem; font-size: 0.66rem; }

h2 {
  margin: 0;
  color: var(--ink);
  font-size: 1.27rem;
  font-weight: 700;
  letter-spacing: -0.025em;
}

.count-pill {
  flex: 0 0 auto;
  padding: 0.38rem 0.65rem;
  border: 1px solid #d5eee9;
  border-radius: 999px;
  background: #effaf7;
  color: #18786d;
  font-size: 0.75rem;
  font-weight: 700;
}

.table-scroll { overflow-x: auto; }

table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.9rem;
}

thead { color: #687b84; }
th {
  padding: 0.72rem 0.7rem;
  border-bottom: 1px solid var(--line);
  font-size: 0.69rem;
  font-weight: 750;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
}

td {
  padding: 0.92rem 0.7rem;
  border-bottom: 1px solid #edf1f1;
  color: #344b56;
  vertical-align: top;
}

tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: #f7fbfa; }
.date-cell, .time-cell { font-variant-numeric: tabular-nums; white-space: nowrap; }
.line-cell { color: #18786d; font-weight: 700; white-space: nowrap; }
.runner-cell { color: #536872; }
.placeholder-row td { color: var(--muted); text-align: center; padding: 1.4rem; }

.board-clock {
  padding: 0.45rem 0.7rem;
  border-radius: 0.55rem;
  background: #effaf7;
  color: #18786d;
  font-size: 0.95rem;
  font-variant-numeric: tabular-nums;
  font-weight: 750;
}

.board-note {
  margin: -0.35rem 0 1rem;
  color: var(--muted);
  font-size: 0.86rem;
}

.departure-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.departure-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.7rem;
  padding: 0.9rem 1rem;
  border: 1px solid var(--line);
  border-radius: 0.7rem;
  background: #fbfdfd;
  color: #49606b;
  font-size: 0.88rem;
}

.departure-list li span:first-child {
  color: var(--ink);
  font-size: 1rem;
  font-variant-numeric: tabular-nums;
  font-weight: 750;
}

.departure-list li span:last-child { color: #18786d; font-weight: 650; }

.load-error {
  margin: 0 0 1rem;
  padding: 0.8rem 0.95rem;
  border: 1px solid #f2cfca;
  border-radius: 0.6rem;
  background: #fff6f4;
  color: #8a3429;
  font-size: 0.88rem;
}

.page-footer {
  display: flex;
  justify-content: center;
  gap: 0.55rem;
  margin-top: 1.7rem;
  color: #61747d;
  font-size: 0.79rem;
}

.footer-separator { color: #9aabad; }

@media (max-width: 700px) {
  .page-shell { width: min(100% - 1.25rem, 1120px); padding-top: 2.15rem; }
  .status-banner { padding-inline: 0.75rem; }
  .incidents-panel, .board-panel { padding: 1.15rem 0.9rem; border-radius: 0.8rem; }
  .section-heading { align-items: flex-start; }
  table { min-width: 700px; }
  .departure-list { grid-template-columns: 1fr; }
  .page-footer { flex-wrap: wrap; }
}
