/* The stations index (templates/pages/stations.html). Only what site.css doesn't have. */

/* Hero with the search box */
.hero .wrap.stations-hero { padding-top: 40px; padding-bottom: 32px; flex-direction: column; flex-wrap: nowrap; align-items: stretch; gap: 18px; }
.station-search { display: flex; flex-wrap: wrap; gap: 10px; max-width: 760px; }
.station-search .input { flex: 1 1 280px; height: 56px; border-radius: 14px; border-color: var(--ink-deep); padding: 0 18px; font-size: 18px; box-shadow: inset 0 3px 0 var(--line); }
.station-search .btn--primary { height: 56px; padding: 0 28px; font-size: 17px; }

/* Nations: big pressable plates, the current one pressed in */
.nations { display: flex; flex-wrap: wrap; gap: 10px; }
.nation { min-width: 200px; padding: 12px 16px; border-radius: 16px; border: 2px solid var(--ink); background: var(--panel); color: var(--ink); box-shadow: 0 4px 0 var(--ink); display: flex; flex-direction: column; gap: 4px; text-decoration: none; }
.nation[aria-current="true"] { background: var(--ink); color: var(--paper); box-shadow: none; transform: translateY(3px); }
.nation[aria-current="true"]:hover { color: var(--paper); }
.nation .name { font-family: var(--display); font-size: 24px; font-weight: 900; text-transform: uppercase; line-height: 1; }
.nation .sub { font-size: 14px; font-weight: 800; }

/* Bars: teal fills, on band in paper panels and on ink-deep in ink ones (site.css .bar) */
.bar > span { background: var(--teal); }
.bar-cell { display: flex; align-items: center; gap: 10px; }
.bar-cell .bar { flex: 1; height: 14px; }
.bar-cell .n { width: 36px; text-align: right; font-weight: 900; color: var(--ink); }

/* Busiest, quietest, managed by */
.busy-row { padding-top: 32px; padding-bottom: 12px; display: flex; flex-wrap: wrap; gap: 24px; align-items: stretch; }
.busiest { flex: 1.3 1 420px; min-width: 0; padding: 20px; display: flex; flex-direction: column; gap: 10px; }
.busiest .heading-row .aside { font-size: 14px; color: var(--muted-ink); }
.busiest ol { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 8px; }
.busiest li { display: grid; grid-template-columns: 24px minmax(130px, 230px) minmax(0, 1fr) 48px; align-items: center; gap: 10px; }
.busiest .rank { font-size: 13px; font-weight: 900; color: var(--muted-ink); }
.busiest li a { font-size: 15px; }
.busiest .bar { height: 14px; }
.busiest .n { font-size: 15px; font-weight: 900; text-align: right; }
.quiet { display: flex; align-items: baseline; gap: 10px; font-size: 15px; font-weight: 900; }
.quiet .name { flex: 1; }
.quiet .n { font-size: 14px; font-weight: 800; color: var(--muted); white-space: nowrap; }
.managers { display: flex; flex-wrap: wrap; gap: 8px; }
.manager { height: 36px; padding: 0 12px; border-radius: 10px; border: 2px solid var(--ink); background: var(--paper); color: var(--ink); display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 900; text-decoration: none; box-shadow: 0 3px 0 var(--ink); }
.manager .n { font-weight: 800; color: var(--muted); }

/* Good for freight */
.freight-stations { display: grid; grid-template-columns: repeat(auto-fit, minmax(270px, 1fr)); gap: 16px; }
.freight-station { background: var(--panel); border: 2px solid var(--ink); border-radius: 18px; box-shadow: 0 5px 0 var(--ink); padding: 16px 18px; display: flex; flex-direction: column; gap: 8px; text-decoration: none; color: var(--ink); }
.freight-station .head { display: flex; align-items: baseline; gap: 10px; }
.freight-station .name { flex: 1; font-family: var(--display); font-size: 26px; font-weight: 900; text-transform: uppercase; line-height: 1; }
.freight-station .crs { font-size: 15px; color: var(--muted); }
.freight-station .line { font-size: 14px; font-weight: 800; color: var(--body-2); }
.freight-station .passed { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 15px; font-weight: 800; }
.freight-station .passed .n { font-size: 22px; font-weight: 900; }
.freight-station .loco { font-size: 14px; font-weight: 900; }
.freight-station .note { font-size: 14px; font-weight: 700; color: var(--muted); }

/* A to Z */
.letters { display: grid; grid-template-columns: repeat(auto-fill, minmax(76px, 1fr)); gap: 8px; }
.letter { height: 64px; border-radius: 14px; border: 2px solid var(--ink); background: var(--panel); color: var(--ink); box-shadow: 0 3px 0 var(--ink); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; text-decoration: none; }
.letter[aria-current="true"] { background: var(--ink); color: var(--paper); box-shadow: none; transform: translateY(3px); }
.letter[aria-current="true"]:hover { color: var(--paper); }
.letter .l { font-family: var(--display); font-size: 26px; font-weight: 900; line-height: 1; }
.letter .n { font-size: 13px; font-weight: 800; }
.letter-foot { gap: 10px 20px; font-size: 15px; font-weight: 800; }

@media (max-width: 520px) {
  .busiest li { grid-template-columns: 20px minmax(0, 1fr) 44px; }
  .busiest .bar { grid-column: 2 / 4; grid-row: 2; }
  .letters { grid-template-columns: repeat(auto-fill, minmax(56px, 1fr)); }
  .nation { min-width: 0; flex: 1 1 140px; }
}
