/* Time to Travel: stylesheet
   Idea: a calm, readable page with one bold element, the dark "departures board" of guides.
   Fonts: Archivo (headings, UI) and Source Serif 4 (reading text), loaded from Google Fonts in each page's <head>.
   System fonts are the fallback, so the site is readable even if the fonts fail to load. */

:root {
  --paper: #f4f6f3;
  --paper-2: #e8eee9;
  --ink: #12202b;
  --ink-soft: #46555f;
  --line: #cdd7d3;
  --brand: #0b5d4b;
  --signal: #f2b400;
  --signal-hover: #ffc928;
  --board: #0f1a1f;
  --board-line: #27373e;
  --board-ink: #f2f5f4;
  --board-soft: #9fb1b6;
  --ok: #43c59e;
  --todo-bg: #fff6d6;
  --todo-ink: #3a2f00;
  --todo-line: #b88700;
  --maxw: 72rem;
  --measure: 42rem;
  --sans: "Archivo", system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --serif: "Source Serif 4", Georgia, "Times New Roman", serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #0d1519;
    --paper-2: #152228;
    --ink: #e7eeee;
    --ink-soft: #a5b5ba;
    --line: #263941;
    --brand: #5fd0b0;
    --board: #1a2a31;
    --board-line: #2f434b;
    --todo-bg: #2b2406;
    --todo-ink: #f5e6a8;
  }
}

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

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.6;
}

img, svg { max-width: 100%; height: auto; }

a {
  color: var(--brand);
  text-underline-offset: 0.18em;
  text-decoration-thickness: 0.08em;
}
a:hover { text-decoration-thickness: 0.16em; }

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

.skip {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--ink);
  color: var(--paper);
  padding: 0.6rem 1rem;
  z-index: 10;
}
.skip:focus { left: 1rem; top: 1rem; }

.wrap {
  width: min(100% - 2rem, var(--maxw));
  margin-inline: auto;
}

/* Header */
.site-header { border-bottom: 1px solid var(--line); }
.site-header .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 2rem;
  padding-block: 1rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--ink);
  text-decoration: none;
  font-weight: 800;
  font-stretch: 80%;
  font-size: 1.6rem;
  letter-spacing: -0.01em;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.5rem;
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav a {
  color: var(--ink-soft);
  text-decoration: none;
  font-weight: 500;
}
.nav a:hover { color: var(--ink); text-decoration: underline; }

/* Home: hero */
.hero { padding-block: clamp(2.5rem, 7vw, 5rem) clamp(1.5rem, 4vw, 2.5rem); }
.hero h1 {
  font-weight: 800;
  font-stretch: 80%;
  font-size: clamp(2.6rem, 7.5vw, 5.2rem);
  line-height: 0.98;
  letter-spacing: -0.02em;
  margin: 0 0 1.25rem;
  max-width: 15ch;
}
.hero p {
  font-family: var(--serif);
  font-size: clamp(1.15rem, 2.2vw, 1.4rem);
  max-width: 36rem;
  color: var(--ink-soft);
  margin: 0;
}

/* Home: the departures board (the one bold element) */
.board {
  background: var(--board);
  color: var(--board-ink);
  border-radius: 6px;
  padding: clamp(1rem, 3vw, 1.75rem);
  margin-block: 1rem 3rem;
}
.board h2 {
  margin: 0 0 1rem;
  font-size: 1.15rem;
  font-weight: 700;
  font-stretch: 85%;
  color: var(--signal);
}
.board table { width: 100%; border-collapse: collapse; }
.board th {
  text-align: left;
  font-weight: 500;
  font-size: 0.85rem;
  color: var(--board-soft);
  padding: 0.4rem 0.75rem 0.6rem 0;
  border-bottom: 1px solid var(--board-line);
}
.board td {
  padding: 0.85rem 0.75rem 0.85rem 0;
  border-bottom: 1px solid var(--board-line);
  vertical-align: baseline;
}
.board tr:last-child td { border-bottom: 0; }
.board .guide-title { font-weight: 700; font-stretch: 90%; font-size: 1.1rem; }
.board .guide-title a { color: var(--board-ink); text-decoration-color: var(--signal); }
.board .is-soon .guide-title { color: var(--board-soft); font-weight: 500; }
.board .num { font-variant-numeric: tabular-nums; white-space: nowrap; color: var(--board-soft); }

.status {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.92rem;
  white-space: nowrap;
}
.status::before {
  content: "";
  width: 0.6rem;
  height: 0.6rem;
  border-radius: 50%;
  background: var(--signal);
}
.status.is-live::before { background: var(--ok); }

@media (max-width: 40rem) {
  .hide-sm { display: none; }
}

/* Home: sections */
.section {
  padding-block: clamp(2rem, 5vw, 3.5rem);
  border-top: 1px solid var(--line);
}
.section-grid {
  display: grid;
  gap: 1rem 3rem;
}
@media (min-width: 48rem) {
  .section-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); }
}
.section h2 {
  margin: 0;
  font-size: clamp(1.6rem, 3.5vw, 2.2rem);
  font-weight: 800;
  font-stretch: 80%;
  line-height: 1.1;
  letter-spacing: -0.01em;
}
.section-body {
  max-width: var(--measure);
  font-family: var(--serif);
  font-size: 1.15rem;
}
.section-body p { margin: 0 0 1rem; }

/* Article and plain pages */
.article { padding-block: 2rem 4rem; }

.crumbs ol {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 0.5rem;
  padding: 0;
  margin: 0 0 1.5rem;
  font-size: 0.95rem;
  color: var(--ink-soft);
}
.crumbs li + li::before { content: "/"; margin-right: 0.5rem; color: var(--ink-soft); }
.crumbs a { color: var(--ink-soft); }

.article-head { max-width: 48rem; }
.article-head h1 {
  font-size: clamp(2.1rem, 5.5vw, 3.6rem);
  line-height: 1.02;
  font-weight: 800;
  font-stretch: 80%;
  letter-spacing: -0.02em;
  margin: 0 0 1rem;
}
.deck {
  font-family: var(--serif);
  font-size: 1.3rem;
  color: var(--ink-soft);
  margin: 0 0 1.25rem;
}
.meta { font-size: 0.95rem; color: var(--ink-soft); margin: 0 0 1rem; }
.notice {
  font-size: 0.95rem;
  border-left: 3px solid var(--line);
  padding-left: 0.9rem;
  color: var(--ink-soft);
  margin: 0 0 2rem;
}

.prose {
  max-width: var(--measure);
  font-family: var(--serif);
  font-size: 1.18rem;
  line-height: 1.7;
}
.prose h2 {
  font-family: var(--sans);
  font-weight: 800;
  font-stretch: 85%;
  font-size: 1.75rem;
  line-height: 1.15;
  letter-spacing: -0.01em;
  margin: 2.75rem 0 0.75rem;
  scroll-margin-top: 1rem;
}
.prose p,
.prose ul,
.prose ol { margin: 0 0 1.1rem; }
.prose li { margin-bottom: 0.4rem; }

.prose .short-answer {
  border-left: 6px solid var(--signal);
  background: var(--paper-2);
  padding: 1rem 1.25rem;
  margin: 0 0 2rem;
}
.prose .short-answer h2 { margin: 0 0 0.4rem; font-size: 1.3rem; }
.prose .short-answer p { margin: 0; }

.table-wrap { overflow-x: auto; margin: 1.25rem 0 1.75rem; }
.prose table {
  width: 100%;
  border-collapse: collapse;
  font-family: var(--sans);
  font-size: 0.98rem;
  line-height: 1.4;
}
.prose caption { text-align: left; font-weight: 700; padding-bottom: 0.5rem; }
.prose th,
.prose td {
  text-align: left;
  padding: 0.6rem 0.75rem 0.6rem 0;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
.prose th { font-weight: 700; border-bottom: 2px solid var(--ink); }

.cta-block { margin: 1.5rem 0 2rem; }
.cta {
  display: inline-block;
  background: var(--signal);
  color: #1a1400;
  font-family: var(--sans);
  font-weight: 700;
  padding: 0.75rem 1.1rem;
  border-radius: 4px;
  text-decoration: none;
}
.cta:hover { background: var(--signal-hover); }
.cta-note {
  font-family: var(--sans);
  font-size: 0.9rem;
  color: var(--ink-soft);
  margin: 0.5rem 0 0;
}

/* Visible reminders for things you must fill in or verify before launch. Delete them when done. */
.todo {
  border: 2px dashed var(--todo-line);
  background: var(--todo-bg);
  color: var(--todo-ink);
  padding: 0.8rem 1rem;
  margin: 1.5rem 0;
  font-family: var(--sans);
  font-size: 0.95rem;
  line-height: 1.5;
  border-radius: 4px;
}

.faq details { border-top: 1px solid var(--line); padding: 0.9rem 0; }
.faq details:last-child { border-bottom: 1px solid var(--line); }
.faq summary {
  cursor: pointer;
  font-family: var(--sans);
  font-weight: 700;
  font-stretch: 90%;
  font-size: 1.1rem;
}
.faq details[open] summary { margin-bottom: 0.6rem; }
.faq details p { margin: 0; }

.sources { font-family: var(--sans); font-size: 0.98rem; }

/* Footer */
.site-footer {
  border-top: 1px solid var(--line);
  padding-block: 2rem 3rem;
  font-size: 0.95rem;
  color: var(--ink-soft);
}
.site-footer .wrap { display: grid; gap: 1rem; }
.site-footer p { margin: 0; max-width: 46rem; }
.site-footer ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  padding: 0;
  margin: 0;
}
.site-footer a { color: var(--ink-soft); }

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; }
}
