/* StageFans design tokens (approved 6 Oct 2026). Ask before adding a font, colour, radius, shadow or animation. */
@font-face { font-family: "Inter"; src: url("/fonts/inter.woff2") format("woff2"); font-weight: 400 600; font-display: swap; }
@font-face { font-family: "Source Serif 4"; src: url("/fonts/sourceserif4.woff2") format("woff2"); font-weight: 600 700; font-display: swap; }

:root {
  --ink: #1A1A1A;
  --paper: #FAF7F2;
  --red: #B3261E;
  --amber: #E8A33D;
  --muted: #5C5650;
  --rule: #D9D2C7;
  --radius: 2px;
  --wide: 1100px;
  --text: 680px;
  --serif: "Source Serif 4", Georgia, serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 16px/1.5 var(--sans); }
a { color: var(--red); text-underline-offset: 2px; }
a:focus-visible, button:focus-visible, input:focus-visible { outline: 3px solid var(--ink); outline-offset: 2px; }
h1, h2, h3 { font-family: var(--serif); font-weight: 700; line-height: 1.15; margin: 0 0 .4em; }
h1 { font-size: clamp(1.9rem, 4.5vw, 2.8rem); letter-spacing: -.01em; }
h2 { font-size: 1.45rem; font-weight: 600; margin-top: 1.6em; }
h3 { font-size: 1.1rem; font-weight: 600; }
p { margin: 0 0 1em; }

.wrap { max-width: var(--wide); margin: 0 auto; padding: 0 16px; }
.prose { max-width: var(--text); }

/* Top bar */
.top { border-bottom: 3px solid var(--ink); }
.top .wrap { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 24px; padding-top: 14px; padding-bottom: 12px; }
.brand { font: 700 1.35rem var(--serif); color: var(--ink); text-decoration: none; margin-right: auto; }
.top nav a { color: var(--ink); font-weight: 600; font-size: .95rem; text-decoration: none; }
.top nav a:hover, .top nav a[aria-current] { text-decoration: underline; text-decoration-thickness: 2px; }
.top nav { display: flex; gap: 18px; flex-wrap: wrap; }

main { padding: 28px 0 48px; }
.lede { font-size: 1.1rem; color: var(--muted); max-width: var(--text); }
.checked { font-size: .9rem; color: var(--muted); }

/* Next to close: the departures line */
.next { border-top: 1px solid var(--ink); border-bottom: 1px solid var(--ink); padding: 10px 0; margin: 20px 0 8px; font-variant-numeric: tabular-nums; }
.next b { font-family: var(--serif); }
.soon { background: var(--amber); color: var(--ink); padding: 0 4px; border-radius: var(--radius); font-weight: 600; }
.board .sub.soon { color: var(--ink); display: inline-block; }
.today { color: var(--red); font-weight: 600; }

/* Sign-up */
.signup { max-width: var(--text); border-left: 4px solid var(--red); padding: 4px 0 4px 16px; margin: 24px 0; }
.signup .flush { margin-top: 0; margin-bottom: 0; }
.signup form { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 8px; margin-top: 8px; }
.signup input[type=email] { flex: 1 1 240px; font: inherit; padding: 10px 12px; border: 1px solid var(--ink); border-radius: var(--radius); background: #fff; color: var(--ink); }
.signup button { font: 600 1rem var(--sans); padding: 10px 18px; border: 1px solid var(--red); border-radius: var(--radius); background: var(--red); color: #fff; cursor: pointer; }
.signup .small { font-size: .85rem; color: var(--muted); margin: 6px 0 0; }
.hp { position: absolute; left: -9999px; }
.signup .email { flex: 1 1 240px; display: flex; flex-direction: column; gap: 4px; font-size: .85rem; color: var(--muted); }
.signup .email input { flex: none; }
.skip { position: absolute; left: -9999px; top: 8px; background: var(--ink); color: var(--paper); padding: 8px 12px; z-index: 10; }
.skip:focus { left: 16px; }
.src { display: inline-block; min-width: 24px; min-height: 24px; text-align: center; }
.terms { font-size: .95rem; }
@media (max-width: 760px) { .next { min-height: calc(4.5em + 20px); } }
.thanks { font-weight: 600; }

/* The board */
table.board { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; margin-top: 12px; }
.board th { text-align: left; font-size: .8rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); border-bottom: 2px solid var(--ink); padding: 8px 10px 6px 0; }
.board th button { font: inherit; text-transform: inherit; letter-spacing: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
.board th button:hover { color: var(--ink); }
.board th[aria-sort] button { color: var(--ink); }
.board th[aria-sort=ascending] button::after { content: " \2191"; }
.board th[aria-sort=descending] button::after { content: " \2193"; }
.board td { vertical-align: top; border-bottom: 1px solid var(--rule); padding: 10px 10px 10px 0; font-size: .95rem; }
.board td.show a { font: 600 1.05rem var(--serif); color: var(--ink); text-decoration: none; }
.board td.show a:hover { text-decoration: underline; }
.board .sub { display: block; color: var(--muted); font-size: .85rem; }
.board .price { font-weight: 600; }
.none { color: var(--muted); }

@media (max-width: 760px) {
  .board thead { display: block; }
  .board thead tr { display: flex; flex-wrap: wrap; gap: 4px 16px; border-bottom: 2px solid var(--ink); padding: 0 0 6px; }
  .board thead tr::before { content: "Sort by"; font-size: .8rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
  .board th { border: 0; padding: 0; }
  .board th button { text-decoration: underline; text-underline-offset: 2px; }
  .board tr { display: block; border-bottom: 1px solid var(--ink); padding: 10px 0; }
  .board td { display: block; border: 0; padding: 2px 0; }
  .board td[data-label]::before { content: attr(data-label) ": "; color: var(--muted); font-size: .85rem; }
}

/* Show pages */
dl.facts { display: grid; grid-template-columns: max-content 1fr; gap: 6px 18px; margin: 0 0 1em; max-width: var(--text); }
dl.facts dt { color: var(--muted); }
dl.facts dd { margin: 0; }
@media (max-width: 520px) { dl.facts { grid-template-columns: 1fr; } dl.facts dd { margin-bottom: 8px; } }
.section { border-top: 1px solid var(--rule); padding-top: 4px; max-width: var(--text); }
.week { list-style: none; padding: 0; margin: 0 0 1em; }
.week li { padding: 6px 0; border-bottom: 1px solid var(--rule); }
.sources { font-size: .85rem; color: var(--muted); word-break: break-word; }
.flag { font-size: .9rem; color: var(--muted); }

/* Actions: reminder, watch, share. Text buttons in the house red, no fills, no shadows */
.acts { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 1em; }
.act { display: inline-block; font: 600 .95rem var(--sans); color: var(--red); background: none; border: 1px solid var(--red); border-radius: var(--radius); padding: 7px 12px; text-decoration: none; cursor: pointer; }
.act:hover, .act[aria-pressed=true] { background: var(--red); color: #fff; }
.star { font: 1.1rem var(--sans); line-height: 1; color: var(--red); background: none; border: 0; min-width: 32px; min-height: 32px; padding: 4px 8px 4px 0; margin: -4px 0; cursor: pointer; vertical-align: middle; }
tr.mine td.show a { text-decoration: underline; text-decoration-color: var(--red); text-decoration-thickness: 2px; }
tr.past td, tr.past td a, tr.past td b { color: var(--muted); }
.find { margin: 18px 0 0; }
.find label { font-size: .85rem; color: var(--muted); display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.find input { flex: 1 1 260px; max-width: 420px; font: inherit; font-size: 1rem; color: var(--ink); padding: 8px 10px; border: 1px solid var(--ink); border-radius: var(--radius); background: #fff; }
.offline { border-left: 4px solid var(--amber); padding-left: 10px; }

footer { border-top: 1px solid var(--ink); padding: 18px 0 32px; font-size: .85rem; color: var(--muted); }
footer a { color: var(--muted); }
