:root {
  --night-ink: #101020;
  --deep-panel: #202030;
  --panel-2: #171727;
  --strange-purple: #8f4dff;
  --true-cyan: #5fd8ff;
  --idea-gold: #ffd166;
  --help-green: #62f6a5;
  --minjerribah-aqua: #90f0e0;
  --soft-white: #f7f3ff;
  --muted-light: #c9c3de;
  --ink-text: #17202a;
  --paper: #f4fbfa;
  --warning: #ff9f6e;
  --heading: "Nunito Sans", "Avenir Next", Arial, sans-serif;
  --body: "Atkinson Hyperlegible", "Source Sans 3", Arial, sans-serif;
  --max-width: 1140px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--night-ink);
  color: var(--soft-white);
  font-family: var(--body);
  font-size: 18px;
  line-height: 1.55;
  overflow-x: clip;
}

img {
  display: block;
  height: auto;
  max-width: 100%;
}

a {
  color: inherit;
}

.skip-link {
  background: var(--idea-gold);
  color: var(--ink-text);
  left: 1rem;
  padding: 0.6rem 0.8rem;
  position: absolute;
  top: -4rem;
  z-index: 20;
}

.skip-link:focus {
  top: 1rem;
}

.site-header {
  background: rgba(16, 16, 32, 0.94);
  border-bottom: 1px solid rgba(144, 240, 224, 0.2);
  position: sticky;
  top: 0;
  z-index: 10;
}

.nav {
  align-items: center;
  display: flex;
  gap: 1rem;
  justify-content: space-between;
  margin: 0 auto;
  max-width: var(--max-width);
  padding: 0.8rem 1.25rem;
}

.brand-mark {
  color: var(--soft-white);
  display: grid;
  font-family: var(--heading);
  font-weight: 900;
  line-height: 0.95;
  text-decoration: none;
  text-transform: uppercase;
}

.brand-mark span:first-child {
  color: var(--strange-purple);
  text-shadow: 0 0 12px rgba(143, 77, 255, 0.75);
}

.brand-mark span:last-child {
  color: var(--idea-gold);
  text-shadow: 0 0 12px rgba(255, 209, 102, 0.55);
}

.nav-links {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  justify-content: flex-end;
}

.nav-links a {
  color: var(--muted-light);
  font-size: 0.92rem;
  font-weight: 700;
  text-decoration: none;
}

.nav-links a:hover,
.nav-links a:focus,
.nav-links a[aria-current="page"] {
  color: var(--minjerribah-aqua);
}

.nav-toggle {
  background: transparent;
  border: 1px solid rgba(247, 243, 255, 0.45);
  border-radius: 8px;
  color: var(--soft-white);
  display: none;
  font-family: var(--heading);
  font-weight: 800;
  padding: 0.55rem 0.75rem;
}

.page-tools {
  align-items: center;
  display: flex;
  gap: 0.75rem;
  margin: 0 auto;
  max-width: var(--max-width);
  padding: 1rem 1.25rem 0;
}

.page-tools a,
.back-button {
  background: transparent;
  border: 1px solid rgba(247, 243, 255, 0.18);
  border-radius: 8px;
  color: var(--minjerribah-aqua);
  cursor: pointer;
  font-family: var(--heading);
  font-size: 0.92rem;
  font-weight: 900;
  padding: 0.45rem 0.65rem;
  text-decoration: none;
}

.hero {
  margin: 0 auto;
  max-width: var(--max-width);
  min-height: calc(100vh - 74px);
  padding: 4rem 1.25rem 3rem;
}

.hero-grid {
  align-items: center;
  display: grid;
  gap: 2.25rem;
  grid-template-columns: minmax(0, 0.95fr) minmax(320px, 0.9fr);
}

.hero-copy {
  max-width: 680px;
}

.eyebrow {
  color: var(--help-green);
  font-family: var(--heading);
  font-size: 0.82rem;
  font-weight: 900;
  letter-spacing: 0;
  margin: 0 0 0.7rem;
  text-transform: uppercase;
}

h1,
h2,
h3,
h4 {
  font-family: var(--heading);
  letter-spacing: 0;
  line-height: 1.04;
  margin: 0;
}

h1 {
  color: var(--soft-white);
  font-size: clamp(2.65rem, 6vw, 5.1rem);
  max-width: 10.5ch;
}

h2 {
  font-size: clamp(2rem, 4.8vw, 3.6rem);
  max-width: 13ch;
}

h3 {
  font-size: 1.35rem;
}

h4 {
  color: var(--idea-gold);
  font-size: 1.05rem;
  margin-top: 1.2rem;
}

p {
  margin: 0;
}

.hero-lede {
  color: var(--muted-light);
  font-size: clamp(1.08rem, 2vw, 1.32rem);
  margin-top: 1.35rem;
  max-width: 38rem;
}

.hero-actions,
.action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-top: 2rem;
}

.button {
  border-radius: 8px;
  display: inline-flex;
  font-family: var(--heading);
  font-weight: 900;
  justify-content: center;
  min-width: 10rem;
  padding: 0.85rem 1rem;
  text-decoration: none;
}

.button.primary {
  background: var(--strange-purple);
  box-shadow: 0 0 22px rgba(143, 77, 255, 0.62);
  color: var(--soft-white);
}

.button.secondary {
  border: 1px solid rgba(95, 216, 255, 0.75);
  color: var(--true-cyan);
}

.hero-visual,
.feature-image {
  margin: 0;
}

.hero-visual img,
.feature-image img {
  background: #05050d;
  border: 1px solid rgba(144, 240, 224, 0.22);
  border-radius: 8px;
  box-shadow: 0 0 38px rgba(95, 216, 255, 0.18), 0 20px 70px rgba(0, 0, 0, 0.55);
  object-fit: contain;
  width: 100%;
}

.hero-visual img {
  max-height: min(66vh, 680px);
}

.signal-strip {
  background: var(--minjerribah-aqua);
  color: var(--ink-text);
  padding: 1rem 1.25rem;
}

.signal-strip-inner {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 0 auto;
  max-width: var(--max-width);
}

.signal-strip strong {
  display: block;
  font-family: var(--heading);
}

.section {
  margin: 0 auto;
  max-width: var(--max-width);
  padding: 5rem 1.25rem;
}

.section.compact {
  padding-top: 2rem;
}

.section-heading {
  max-width: 820px;
}

.section-heading p:not(.eyebrow) {
  color: var(--muted-light);
  margin-top: 1rem;
}

.split {
  align-items: center;
  display: grid;
  gap: 2rem;
  grid-template-columns: minmax(0, 0.95fr) minmax(280px, 0.72fr);
}

.panel,
.question-card,
.source-card,
.step-card {
  background: var(--deep-panel);
  border: 1px solid rgba(247, 243, 255, 0.12);
  border-radius: 8px;
  padding: 1.25rem;
}

.panel.warning {
  border-color: rgba(255, 159, 110, 0.5);
}

.panel h3,
.question-card h3,
.source-card h3,
.step-card h3 {
  color: var(--true-cyan);
}

.panel p,
.question-card p,
.source-card p,
.step-card p,
.page-copy {
  color: var(--muted-light);
  margin-top: 0.75rem;
}

.grid,
.source-grid,
.step-grid {
  display: grid;
  gap: 1rem;
  margin-top: 2rem;
}

.grid.three,
.source-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.grid.four {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.step-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.mini-grid {
  display: grid;
  gap: 0.75rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.mini-grid div {
  background: rgba(5, 5, 13, 0.4);
  border: 1px solid rgba(247, 243, 255, 0.1);
  border-radius: 8px;
  padding: 0.85rem;
}

.mini-grid strong {
  color: var(--idea-gold);
  display: block;
  font-family: var(--heading);
  font-size: 0.86rem;
}

.mini-grid span {
  color: var(--muted-light);
  display: block;
  font-size: 0.95rem;
  margin-top: 0.35rem;
}

details {
  border-top: 1px solid rgba(247, 243, 255, 0.14);
  padding-top: 0.75rem;
}

summary {
  color: var(--help-green);
  cursor: pointer;
  font-family: var(--heading);
  font-weight: 900;
}

ul,
ol {
  color: var(--soft-white);
  margin: 0.8rem 0 0;
  padding-left: 1.25rem;
}

li + li {
  margin-top: 0.42rem;
}

li::marker {
  color: var(--help-green);
}

.source-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.source-row a,
.text-link {
  color: var(--minjerribah-aqua);
  font-weight: 700;
}

.source-row a {
  border: 1px solid rgba(144, 240, 224, 0.22);
  border-radius: 8px;
  font-size: 0.86rem;
  padding: 0.35rem 0.45rem;
  text-decoration: none;
}

.anchor-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-top: 1.5rem;
}

.anchor-nav a {
  border: 1px solid rgba(144, 240, 224, 0.28);
  border-radius: 8px;
  color: var(--minjerribah-aqua);
  font-family: var(--heading);
  font-size: 0.9rem;
  font-weight: 900;
  padding: 0.5rem 0.65rem;
  text-decoration: none;
}

.anchor-nav a:hover,
.anchor-nav a:focus {
  border-color: rgba(95, 216, 255, 0.8);
  color: var(--soft-white);
  box-shadow: 0 0 16px rgba(95, 216, 255, 0.16);
}

.copy-button {
  background: transparent;
  border: 1px solid rgba(144, 240, 224, 0.35);
  border-radius: 8px;
  color: var(--minjerribah-aqua);
  cursor: pointer;
  font-family: var(--heading);
  font-weight: 900;
  padding: 0.65rem 0.8rem;
}

.copy-button:hover,
.copy-button:focus {
  border-color: rgba(95, 216, 255, 0.8);
  color: var(--soft-white);
  box-shadow: 0 0 16px rgba(95, 216, 255, 0.16);
}

.record-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1rem;
}

.record-actions a {
  display: inline-flex;
  text-decoration: none;
}

.form-status {
  color: var(--muted-light);
  font-size: 0.95rem;
  margin-top: 0.25rem;
}

.copy-button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.hidden-frame {
  border: 0;
  height: 1px;
  left: -9999px;
  position: absolute;
  width: 1px;
}

.mapper-shell {
  align-items: start;
  display: grid;
  gap: 1rem;
  grid-template-columns: minmax(0, 0.72fr) minmax(320px, 0.88fr);
  margin-top: 2rem;
}

.mapper-form {
  background: var(--deep-panel);
  border: 1px solid rgba(144, 240, 224, 0.2);
  border-radius: 8px;
  display: grid;
  gap: 1rem;
  padding: 1.25rem;
}

.contact-form {
  margin-top: 2rem;
  max-width: 760px;
}

.mapper-form fieldset {
  border: 1px solid rgba(144, 240, 224, 0.18);
  border-radius: 8px;
  display: grid;
  gap: 1rem;
  margin: 0;
  padding: 1rem;
}

.mapper-form legend {
  color: var(--idea-gold);
  font-family: var(--heading);
  font-size: 1rem;
  font-weight: 900;
  padding: 0 0.35rem;
}

.mapper-form label {
  color: var(--soft-white);
  display: grid;
  font-family: var(--heading);
  font-weight: 900;
  gap: 0.35rem;
}

.mapper-form span {
  color: var(--muted-light);
  font-family: var(--body);
  font-size: 0.9rem;
  font-weight: 400;
}

.mapper-form input,
.mapper-form select,
.mapper-form textarea {
  background: var(--panel-2);
  border: 1px solid rgba(247, 243, 255, 0.18);
  border-radius: 8px;
  color: var(--soft-white);
  font: inherit;
  padding: 0.8rem;
  width: 100%;
}

.new-location-fields {
  border-left: 3px solid rgba(95, 216, 255, 0.6);
  display: grid;
  gap: 1rem;
  padding-left: 1rem;
}

.new-location-fields[hidden] {
  display: none;
}

.checkbox-group {
  display: grid;
  gap: 0.65rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.checkbox-group label {
  align-items: center;
  background: rgba(5, 5, 13, 0.35);
  border: 1px solid rgba(247, 243, 255, 0.12);
  border-radius: 8px;
  display: flex;
  gap: 0.5rem;
  padding: 0.65rem;
}

.checkbox-group input {
  width: auto;
}

.record-sections {
  display: grid;
  gap: 0.85rem;
  margin-top: 1rem;
}

.question-batch {
  background: rgba(5, 5, 13, 0.32);
  border: 1px solid rgba(144, 240, 224, 0.14);
  border-radius: 8px;
  padding: 0.85rem;
}

.mapper-output {
  background: linear-gradient(135deg, rgba(32, 32, 48, 0.96), rgba(16, 16, 32, 0.98));
  border: 1px solid rgba(144, 240, 224, 0.24);
  border-radius: 8px;
  min-height: 28rem;
  padding: 1.25rem;
}

.mapper-output p {
  color: var(--muted-light);
  margin-top: 0.7rem;
}

.notice-output {
  background: #05050d;
  border: 1px solid rgba(144, 240, 224, 0.24);
  border-radius: 8px;
  color: var(--soft-white);
  font: 0.9rem Consolas, "Courier New", monospace;
  min-height: 20rem;
  margin-top: 1rem;
  padding: 1rem;
  resize: vertical;
  width: 100%;
}

.transport-map {
  background: var(--paper);
  border-radius: 8px;
  color: var(--ink-text);
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  padding: 1.25rem;
}

.transport-node {
  background: #ffffff;
  border: 1px solid rgba(23, 32, 42, 0.12);
  border-radius: 8px;
  padding: 1rem;
}

.transport-node h3 {
  color: #2637a1;
}

.transport-node p {
  color: #39414d;
  margin-top: 0.6rem;
}

.path-arrow {
  align-self: center;
  color: #267a5a;
  font-family: var(--heading);
  font-weight: 900;
  text-align: center;
}

.notice-demo {
  background: rgba(5, 5, 13, 0.42);
  border: 1px solid rgba(144, 240, 224, 0.24);
  border-radius: 8px;
  display: grid;
  gap: 1rem;
  grid-template-columns: minmax(0, 0.82fr) minmax(280px, 0.7fr);
  margin-top: 2rem;
  padding: 1.25rem;
}

.notice-demo pre {
  background: #05050d;
  border: 1px solid rgba(247, 243, 255, 0.14);
  border-radius: 8px;
  color: var(--soft-white);
  margin: 0;
  overflow-x: auto;
  padding: 1rem;
  white-space: pre-wrap;
}

.flow-line {
  display: grid;
  gap: 0.85rem;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  margin-top: 2rem;
}

.flow-step {
  background: linear-gradient(160deg, rgba(32, 32, 48, 0.96), rgba(16, 16, 32, 0.96));
  border: 1px solid rgba(144, 240, 224, 0.24);
  border-radius: 8px;
  padding: 1rem;
}

.flow-step span {
  align-items: center;
  background: var(--idea-gold);
  border-radius: 999px;
  color: var(--ink-text);
  display: inline-flex;
  font-family: var(--heading);
  font-weight: 900;
  height: 2rem;
  justify-content: center;
  width: 2rem;
}

.flow-step h3 {
  color: var(--true-cyan);
  margin-top: 0.85rem;
}

.flow-step p {
  color: var(--muted-light);
  margin-top: 0.7rem;
}

.source-card a {
  color: var(--minjerribah-aqua);
}

.card-tag {
  color: var(--idea-gold);
  font-family: var(--heading);
  font-size: 0.8rem;
  font-weight: 900;
  margin: 0 0 0.65rem;
  text-transform: uppercase;
}

.network-card .text-link {
  display: inline-flex;
  margin-top: 1rem;
}

.source-card .mini-grid {
  grid-template-columns: 1fr;
  margin-top: 1rem;
}

.source-card .source-row {
  margin-top: 1rem;
}

.table-stack {
  display: grid;
  gap: 1rem;
  margin-top: 2rem;
  min-width: 0;
}

.timetable-block h3 {
  color: var(--true-cyan);
}

.timetable-block {
  min-width: 0;
  overflow: hidden;
}

.table-scroll {
  border: 1px solid rgba(144, 240, 224, 0.18);
  border-radius: 8px;
  margin-top: 1rem;
  max-width: 100%;
  min-width: 0;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scrollbar-color: rgba(144, 240, 224, 0.5) rgba(5, 5, 13, 0.65);
}

.data-table {
  border-collapse: collapse;
  min-width: 620px;
  width: 100%;
}

.data-table.wide {
  min-width: 920px;
}

.data-table.official-bus {
  min-width: 1480px;
}

.data-table.official-bus.route-881 {
  min-width: 880px;
}

.data-table caption {
  color: var(--true-cyan);
  font-family: var(--heading);
  font-size: 1rem;
  font-weight: 900;
  padding: 0.75rem;
  text-align: left;
}

.data-table th,
.data-table td {
  border-bottom: 1px solid rgba(247, 243, 255, 0.12);
  padding: 0.72rem;
  text-align: left;
  vertical-align: top;
}

.data-table th {
  background: rgba(5, 5, 13, 0.45);
  color: var(--idea-gold);
  font-family: var(--heading);
  font-size: 0.9rem;
}

.data-table td {
  color: var(--muted-light);
  font-size: 0.94rem;
}

.official-bus td:nth-child(n+2),
.official-bus th:nth-child(n+2) {
  text-align: center;
  white-space: nowrap;
}

.official-bus th:first-child {
  min-width: 15rem;
  text-align: left;
}

.data-table tr:last-child td {
  border-bottom: 0;
}

.timetable-block .source-row,
.timetable-note {
  margin-top: 1rem;
}

.timetable-note {
  color: var(--muted-light);
  font-size: 0.95rem;
}

a.source-card {
  color: inherit;
  display: block;
  text-decoration: none;
}

a.source-card:hover,
a.source-card:focus {
  border-color: rgba(144, 240, 224, 0.55);
}

.site-footer {
  align-items: center;
  border-top: 1px solid rgba(247, 243, 255, 0.12);
  color: var(--muted-light);
  display: flex;
  gap: 1rem;
  justify-content: space-between;
  margin: 0 auto;
  max-width: var(--max-width);
  padding: 1.5rem 1.25rem 2rem;
}

.sequence-nav {
  border-top: 1px solid rgba(247, 243, 255, 0.12);
  display: grid;
  gap: 0.85rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 1rem auto 0;
  max-width: var(--max-width);
  padding: 1.25rem 1.25rem 2.4rem;
}

.sequence-link {
  align-items: center;
  background: rgba(32, 32, 48, 0.88);
  border: 1px solid rgba(144, 240, 224, 0.22);
  border-radius: 8px;
  color: var(--soft-white);
  display: flex;
  font-family: var(--heading);
  font-size: 1rem;
  font-weight: 900;
  gap: 0.8rem;
  justify-content: space-between;
  min-height: 4.2rem;
  padding: 0.9rem 1rem;
  text-decoration: none;
}

.sequence-link.previous::before,
.sequence-link.next::after {
  color: var(--minjerribah-aqua);
  font-size: 1.35rem;
  line-height: 1;
}

.sequence-link.previous::before {
  content: "<";
}

.sequence-link.next::after {
  content: ">";
}

.sequence-link.previous {
  justify-content: flex-start;
}

.sequence-link.next {
  justify-content: flex-end;
  text-align: right;
}

.sequence-link:hover,
.sequence-link:focus {
  background: rgba(38, 38, 58, 0.98);
  border-color: rgba(95, 216, 255, 0.8);
  box-shadow: 0 0 18px rgba(95, 216, 255, 0.16);
}

.sequence-kicker {
  color: var(--idea-gold);
  display: block;
  font-size: 0.72rem;
  letter-spacing: 0;
  line-height: 1;
  margin-bottom: 0.25rem;
  text-transform: uppercase;
}

.footer-copy {
  display: grid;
  gap: 0.3rem;
}

.footer-note {
  color: rgba(201, 195, 222, 0.78);
  font-size: 0.92rem;
}

.to-top {
  background: var(--strange-purple);
  border: 0;
  border-radius: 999px;
  bottom: 1.25rem;
  box-shadow: 0 0 20px rgba(143, 77, 255, 0.55);
  color: var(--soft-white);
  cursor: pointer;
  font-family: var(--heading);
  font-size: 0.95rem;
  font-weight: 900;
  opacity: 0;
  padding: 0.8rem 1rem;
  pointer-events: none;
  position: fixed;
  right: 1.25rem;
  transform: translateY(0.5rem);
  transition: opacity 180ms ease, transform 180ms ease;
  z-index: 30;
}

.to-top.is-visible {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

@media (max-width: 920px) {
  .nav {
    align-items: start;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .nav-links {
    background: var(--night-ink);
    border: 1px solid rgba(247, 243, 255, 0.15);
    border-radius: 8px;
    display: none;
    flex-direction: column;
    gap: 0.2rem;
    padding: 0.75rem;
    position: absolute;
    right: 1.25rem;
    top: 4.4rem;
  }

  .nav-links.is-open {
    display: flex;
  }

  .nav-links a {
    padding: 0.45rem 0.3rem;
  }

  .hero-grid,
  .split,
  .mapper-shell,
  .notice-demo {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
    padding-top: 3rem;
  }

  .signal-strip-inner,
  .checkbox-group,
  .grid.three,
  .grid.four,
  .source-grid,
  .step-grid,
  .flow-line,
  .transport-map {
    grid-template-columns: 1fr 1fr;
  }

  .hero-visual img {
    max-height: none;
  }
}

@media (max-width: 620px) {
  body {
    font-size: 16px;
  }

  .hero,
  .section {
    padding-left: 1rem;
    padding-right: 1rem;
  }

  .signal-strip-inner,
  .checkbox-group,
  .grid.three,
  .grid.four,
  .source-grid,
  .step-grid,
  .flow-line,
  .mini-grid,
  .transport-map {
    grid-template-columns: 1fr;
  }

  .button {
    width: 100%;
  }

  .sequence-nav {
    grid-template-columns: 1fr;
  }

  .sequence-link.next {
    justify-items: start;
    text-align: left;
  }

  .site-footer {
    align-items: start;
    flex-direction: column;
  }
}
