/* The statewide directory shares the city guides' ink, paper and station marks. */
.directory-home .toprow { min-height: 3.85rem; }
.directory-home .topbar .brand { font-size: 1.55rem; }
.directory-home .topbar .brand svg { width: 2.1rem; height: 2.1rem; }
.route-directory { background: var(--paper); border-bottom: 1px solid var(--line); }
.desk-wrap { width: min(100%, 92rem); margin-inline: auto; padding-inline: var(--gutter); }
.network-desk { border-bottom: 4px solid var(--gold); background: #173e45; }
.desk-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem 2rem; padding-block: 1.25rem 1rem; }
.desk-head h1 { font: 750 clamp(1.9rem, 3.5vw, 3.1rem)/1.07 var(--head); letter-spacing: -.045em; }
.desk-head p { margin-top: .27rem; color: #d9e2d5; font-size: 1.06rem; }
.city-control { display: flex; align-items: center; gap: .75rem; }
.city-control label, .record-kind, .record-region, .chart-key, .next-stops strong {
  font: 650 .72rem/1.4 var(--mono); letter-spacing: .07em; text-transform: uppercase;
}
.city-control label { color: #e3eadd; }
.city-control select { width: 12.5rem; max-width: 100%; min-height: 44px; padding: .55rem .65rem; background: var(--paper); color: var(--ink); border: 1px solid var(--cream); border-radius: 3px; font: 700 1.02rem var(--ui); }
.network-desk :is(a, select, summary):focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }
.skip-network { position: absolute; clip-path: inset(50%); width: 1px; height: 1px; overflow: hidden; }
.skip-network:focus { clip-path: none; width: auto; height: auto; background: var(--deep); padding: .4rem .7rem; z-index: 1; }
.network-figure { background: #204a50; border: 1px solid #5a7775; }
.network { width: 100%; height: auto; display: block; }
.tracks { stroke-width: 5; }
.highway-track { stroke: #f1cc87; }
.rail-track { stroke: #f49978; }
.regional-track { stroke: #a9d6c8; stroke-width: 4; stroke-dasharray: 8 7; }
.network-stop { cursor: pointer; }
.network-stop text { fill: #fff7df; font: 700 17px var(--head); paint-order: stroke; stroke: #204a50; stroke-width: 5px; stroke-linejoin: round; }
.hit-area { fill: transparent; }
.stop-dot { fill: #f5ecd6; stroke: #173e45; stroke-width: 2; }
.transfer-ring { fill: #204a50; stroke: #f6efdf; stroke-width: 2.5; }
.state-ring { fill: transparent; stroke: transparent; stroke-width: 3; }
.network-stop[aria-current] .state-ring { fill: #f4bd6426; stroke: var(--gold); }
.network-stop[aria-current] .stop-dot { fill: var(--gold); }
.network-stop[aria-current] text { fill: #ffdc97; }
.network-stop:is(:hover, :focus-visible) .state-ring { stroke: white; stroke-width: 4; }
.network-stop:is(:hover, :focus-visible) text { text-decoration: underline; }
.chart-key { display: flex; align-items: center; gap: .45rem 1.6rem; flex-wrap: wrap; padding: .6rem .9rem; margin: 0; border-top: 1px solid #587471; background: #1d444a; color: #e3e8d6; font-size: .68rem; letter-spacing: .035em; }
.chart-key span { display: inline-flex; align-items: center; gap: .5rem; }
.chart-key i { width: 1.6rem; border-top: 3px solid; }
.key-highway { color: #f1cc87; }
.key-rail { color: #f49978; }
.chart-key .key-regional { color: #a9d6c8; border-top-style: dashed; }
.schematic-note { margin-left: auto; font-weight: 400; }
.network-tools { display: flex; position: relative; flex-wrap: wrap; align-items: start; gap: 0 1.65rem; }
.network-tools summary, .jump-result { cursor: pointer; display: flex; align-items: center; gap: .5rem; min-height: 46px; padding-block: .35rem; font: 650 .88rem/1.4 var(--ui); }
.network-tools summary::-webkit-details-marker { display: none; }
.network-tools summary:hover { color: var(--gold); }
.interchange-symbol { width: .9rem; height: .9rem; border: 3px double currentColor; border-radius: 50%; }
.menu-arrow { font-size: 1.05rem; }
details[open] > summary .menu-arrow { transform: rotate(180deg); }
.jump-result { margin-left: auto; color: #f3d297; }
.network-tools:has(details[open]) { display: block; }
.transfer-options, .stop-groups { background: #214b50; border-top: 1px solid #62817e; padding: .6rem 1rem; }
.transfer-options { display: flex; flex-wrap: wrap; gap: .2rem 1.35rem; }
.transfer-options a, .stop-groups a { display: inline-flex; min-height: 44px; align-items: center; font: 640 .94rem var(--ui); }
.network-tools a[aria-current] { color: #ffdc97; font-weight: 800; text-decoration-thickness: 3px; }
.stop-groups { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 1rem; }
.stop-groups h3 { margin-block: .45rem .3rem; color: var(--gold); font-size: 1.1rem; letter-spacing: 0; }
.stop-groups ul { list-style: none; margin: 0 0 .5rem .3rem; padding: 0 0 0 .9rem; border-left: 2px solid #78a89c; }
.stop-groups li { position: relative; }
.stop-groups li::before { content: ""; position: absolute; top: 1.13rem; left: -1.2rem; width: .46rem; height: .46rem; border: 1px solid #a9d6c8; border-radius: 50%; background: #214b50; }
.records { padding-block: 1.35rem 1.5rem; }
.station-record { scroll-margin-block-start: .75rem; }
.station-record + .station-record { margin-top: 1.75rem; }
.records[data-enhanced] .station-record { margin-top: 0; }
/* Native fragment links still switch records when scripting is disabled.
   Browsers without :has() display every record in document order. */
@supports selector(:has(> article:target)) {
  .records:not([data-enhanced]) .station-record { display: none; margin-top: 0; }
  .records:not([data-enhanced]):not(:has(> article:target)) .station-record:first-of-type,
  .records:not([data-enhanced]) .station-record:target { display: block; }
}
.record-head { display: flex; align-items: center; justify-content: space-between; gap: .8rem; padding-bottom: .92rem; }
.record-region { margin-bottom: .25rem; color: var(--rust); }
.record-head h2 { font-size: clamp(2.05rem, 3.6vw, 3.25rem); }
.guide-link, .operator, .next-stops a { min-height: 44px; display: inline-flex; align-items: center; gap: .4rem; font: 680 .9rem/1.35 var(--ui); }
.guide-link { flex-shrink: 0; }
.record-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); border: 1px solid var(--line); background: #fcf7e9; }
.record-column { position: relative; min-width: 0; padding: 1.05rem clamp(.95rem, 2vw, 1.75rem) .7rem; display: flex; flex-direction: column; }
.record-column + .record-column { border-left: 1px solid var(--line); }
.record-column.municipal { background: #e8ebdf; }
.record-kind { display: flex; align-items: center; gap: .48rem; color: var(--rust); }
.municipal .record-kind { color: #345957; }
.record-column h3 { margin-block: .46rem .48rem; font-size: clamp(1.35rem, 2.1vw, 1.85rem); }
.record-column > p:not(.record-kind) { font-size: 1.015rem; line-height: 1.5; }
.operator-links { display: flex; flex-wrap: wrap; gap: 0 1rem; margin-top: auto; padding-top: .4rem; }
.operator { color: #833b2f; }
.municipal .operator { color: #254d48; }
.next-stops { display: flex; flex-wrap: wrap; align-items: center; gap: .12rem 1.35rem; margin-top: .4rem; }
.next-stops strong { color: var(--muted); font-size: .69rem; }
.next-stops a { font-size: .85rem; }
.next-stops a span { font-weight: 500; }
.return-stops { margin-left: auto; }
.region ul, .directory-list, .task-list, .clean { list-style: none; padding: 0; }

.task-list a::after { content: "→"; color: var(--rust); }
.task-list a:hover { text-decoration: underline; }
.fork-label { margin-bottom: .5rem; font: 700 .73rem var(--mono); text-transform: uppercase; letter-spacing: .1em; }
.branch-list { list-style: none; position: relative; padding-left: 2.6rem; }
.branch-list::before { content: ""; position: absolute; left: .55rem; top: 25%; height: 50%; width: 1.8rem; border: solid var(--rust); border-width: 2px 0 2px 2px; border-radius: .8rem 0 0 .8rem; }
.branch-list::after { content: ""; position: absolute; left: .27rem; top: calc(50% - .31rem); width: .62rem; height: .62rem; background: var(--paper); border: 2px solid var(--rust); border-radius: 50%; }
.branch-list li + li { border-top: 1px solid var(--line); }
.branch-list a { display: flex; align-items: center; justify-content: space-between; gap: .5rem; text-decoration: none; min-height: 45px; padding: .35rem .25rem; font: 730 1.12rem/1.25 var(--head); }
.branch-list a:hover { text-decoration: underline; }
.branch-list a::after { content: "→"; font: 1.15rem var(--ui); }
.service-grid { display: grid; grid-template-columns: 1fr 1.3fr; gap: clamp(1.5rem,5vw,5rem); }
.service-grid h2 { margin-block: .6rem 1rem; }
.task-list a { display: flex; align-items: center; gap: 1rem; justify-content: space-between; min-height: 49px; border-top: 1px solid var(--line); padding: .55rem 0; text-decoration: none; font: 700 1.09rem var(--ui); }

@media (max-width: 62rem) {
  .network-figure { display: none; }
  .network-tools { border-top: 1px solid #617c79; }
  .stop-groups { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .desk-head { flex-wrap: wrap; }
  .desk-head h1 { font-size: clamp(1.85rem,5vw,2.7rem); }
  .next-stops .return-stops { margin-left: 0; }
}
@media (max-width: 45rem) {
  .service-grid, .record-grid { grid-template-columns: 1fr; }
  .record-column + .record-column { border-left: 0; border-top: 1px solid var(--line); }
  .directory-home .toprow { padding-top: .32rem; }
  .directory-home .toprow .inline-nav { gap: 0 .9rem; font-size: .83rem; margin-top: 0; }
  .desk-head { gap: .7rem; padding-block: .95rem .75rem; }
  .desk-head p { font-size: 1rem; }
  .city-control { width: 100%; justify-content: space-between; }
  .city-control select { flex: 1; max-width: 18rem; }
  .network-tools { gap: 0 1.2rem; }
  .jump-result { display: none; }
  .records { padding-top: 1rem; }
  .record-head { flex-wrap: wrap; }
  .stop-groups { grid-template-columns: repeat(auto-fit,minmax(min(11rem,100%),1fr)); }
  .next-stops { display: block; padding-top: .8rem; }
  .next-stops strong { display: block; }
  .next-stops a { display: flex; width: fit-content; }
}
