:root {
  color-scheme: light dark;
  --page-background: #fff;
  --surface: #fff;
  --raised-surface: #eee;
  --text: rgba(0, 0, 0, .87);
  --muted-text: rgba(0, 0, 0, .54);
  --border: #8a8a8a;
  --divider: rgba(0, 0, 0, .12);
  --link: #039be5;
  --navigation: #8b1014;
  --navigation-hover: rgba(0, 0, 0, .1);
  --menu-hover: rgba(0, 0, 0, .05);
  --action: #26a69a;
  --action-hover: #2bbbad;
  --danger: #f44336;
  --shadow: rgba(0, 0, 0, .75);
  --warning-background: #fff3e0;
  --alert-background: #ffebee;
  --sidebar-width: 300px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --page-background: #121212;
    --surface: #1d1d1d;
    --raised-surface: #292929;
    --text: rgba(255, 255, 255, .87);
    --muted-text: rgba(255, 255, 255, .65);
    --border: #777;
    --divider: rgba(255, 255, 255, .2);
    --link: #63c5f3;
    --navigation: #731015;
    --navigation-hover: rgba(255, 255, 255, .1);
    --menu-hover: rgba(255, 255, 255, .08);
    --action: #168f85;
    --action-hover: #20a99c;
    --shadow: rgba(0, 0, 0, .95);
    --warning-background: #382c19;
    --alert-background: #3b2023;
  }
}

@font-face {
  font-family: "Material Icons";
  font-style: normal;
  font-weight: 400;
  font-display: block;
  src: url(../fonts/flUhRq6tzZclQEJ-Vdg-IuiaDsNc.woff2) format("woff2");
}

@font-face {
  font-family: Karla;
  font-weight: 700;
  font-display: swap;
  src: url(../fonts/Karla-Bold.ttf) format("truetype");
}

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

html {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  font-size: 14px;
  font-weight: 400;
  line-height: 1.5;
  color: var(--text);
  background: var(--page-background);
}

body {
  margin: 0;
  color: var(--text);
  background: var(--page-background);
}

a {
  color: var(--link);
  text-decoration: none;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-weight: 400;
  line-height: 1.3;
}

h1 {
  margin: 2.13333rem 0 1.28rem;
  font-size: 3.2rem;
  line-height: 1.1;
}

h2 {
  margin: 1.70667rem 0 1.024rem;
  font-size: 2.56rem;
  line-height: 1.1;
}

h3 {
  margin: 1.28rem 0 .768rem;
  font-size: 1.92rem;
  line-height: 1.1;
}

h4 {
  margin: .85333rem 0 .512rem;
  font-size: 1.28rem;
  line-height: 1.1;
}

small {
  font-size: 75%;
}

address {
  font-style: normal;
}

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

svg.line-symbol {
  overflow: visible;
  filter: drop-shadow(1px 1px 2px currentColor);
}

svg.line-symbol:hover {
  filter: drop-shadow(1px 1px 2px #000);
}

.app-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: "Material Icons";
  font-size: 24px;
  font-style: normal;
  font-weight: 400;
  line-height: 1;
  letter-spacing: normal;
  text-transform: none;
  vertical-align: middle;
  white-space: nowrap;
  word-wrap: normal;
  direction: ltr;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.app-icon--medium {
  font-size: 3rem;
}

.app-icon--large {
  font-size: 1.6rem;
}

.visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

.text-center {
  text-align: center;
}

.text-right {
  text-align: right;
}

.clear {
  clear: both;
}

.nowrap {
  white-space: nowrap;
}

.content-row {
  display: flex;
  flex-wrap: wrap;
  margin-right: -.75rem;
  margin-bottom: 20px;
  margin-left: -.75rem;
}

.content-row > * {
  min-height: 1px;
  padding: 0 .75rem;
}

.content-block {
  width: 100%;
}

.readable {
  font-size: clamp(1.2rem, calc(1.02rem + .8vw), 1.68rem);
}

.separator {
  height: 1px;
  overflow: hidden;
  background: var(--divider);
}

.content-section {
  padding-top: 1rem;
  padding-bottom: 1rem;
}

.action-button {
  display: inline-block;
  height: 36px;
  padding: 0 16px;
  border: 0;
  border-radius: 2px;
  color: #fff;
  background: var(--action);
  font-size: 14px;
  line-height: 36px;
  letter-spacing: .5px;
  text-align: center;
  text-transform: uppercase;
  vertical-align: middle;
  cursor: pointer;
  transition: background-color .2s ease-out;
}

.action-button:hover,
.action-button:focus-visible {
  color: #fff;
  background: var(--action-hover);
}

.action-button--current {
  color: var(--text);
  background: transparent;
  box-shadow: none;
  cursor: default;
}

.action-button--current:hover,
.action-button--current:focus-visible {
  color: var(--text);
  background: var(--menu-hover);
}

.site-header,
.site-footer {
  padding-left: var(--sidebar-width);
}

.site-main {
  padding-left: calc(var(--sidebar-width) + 20px);
}

.topbar {
  width: 100%;
  height: 56px;
  color: #fff;
  background: var(--navigation);
  line-height: 56px;
}

.topbar__inner {
  position: relative;
  height: 100%;
}

.topbar__brand {
  position: absolute;
  right: .5rem;
  display: inline-block;
  padding: 0;
  color: #fff;
  font-size: 2.1rem;
}

.topbar__links {
  float: left;
  padding: 0;
  margin: 0;
  list-style: none;
}

.topbar__links li {
  float: left;
}

.topbar__links a {
  display: block;
  padding: 0 15px;
  color: #fff;
  font-size: 1rem;
  transition: background-color .3s;
}

.topbar__current {
  display: block;
  padding: 0 15px;
  color: #fff;
  font-size: 1rem;
}

.topbar__links a:hover,
.topbar__links a:focus-visible,
.topbar__links .is-active {
  background: var(--navigation-hover);
}

.site-name {
  text-transform: uppercase;
}

.menu-toggle {
  position: relative;
  z-index: 1;
  display: none;
  float: left;
  height: 56px;
  padding: 0;
  margin: 0 18px;
  border: 0;
  color: #fff;
  background: transparent;
  line-height: 56px;
  cursor: pointer;
}

.menu-toggle .app-icon {
  height: 56px;
  line-height: 56px;
}

.site-menu {
  position: fixed;
  z-index: 1000;
  top: 0;
  left: 0;
  width: var(--sidebar-width);
  height: 100vh;
  padding-bottom: 60px;
  overflow-y: auto;
  color: var(--text);
  background: var(--surface);
  box-shadow: 2px 0 6px rgba(0, 0, 0, .18);
  transition: transform .2s ease-out;
}

.site-menu__list {
  padding: 0;
  margin: 0;
  list-style: none;
}

.site-menu__banner,
.site-menu__banner a,
.site-menu__banner img {
  display: block;
  width: 100%;
}

.site-menu__item {
  line-height: 48px;
}

.site-menu__item > a,
.site-menu__current {
  display: block;
  height: 48px;
  padding: 0 32px;
  overflow: hidden;
  color: var(--text);
  font-size: 14px;
  font-weight: 500;
  line-height: 48px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.site-menu__current {
  color: var(--muted-text);
  cursor: default;
}

.site-menu__item > a:hover,
.site-menu__item > a:focus-visible {
  background: var(--menu-hover);
}

.site-menu__item > a > span {
  margin-right: 6px;
}

.site-menu__item > a > .app-icon {
  float: left;
  width: 24px;
  height: 48px;
  margin-right: 10px;
  color: var(--muted-text);
  line-height: 48px;
}

.site-menu__heading {
  display: block;
  height: 48px;
  padding: 0 32px;
  color: var(--muted-text);
  font-size: 14px;
  font-weight: 500;
  line-height: 48px;
}

.site-menu__help {
  padding-left: 32px;
  line-height: 1.5;
}

.menu-overlay {
  position: fixed;
  z-index: 999;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  display: none;
  border: 0;
  background: rgba(0, 0, 0, .5);
  cursor: pointer;
}

.line-list {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  margin: 0 -.75rem 20px;
}

.line-list__item {
  grid-column: span 4;
  min-width: 0;
  padding: 0 .75rem;
  text-align: center;
}

.line-list--detailed .line-list__item {
  grid-column: 1 / -1;
  text-align: left;
}

.line-list__content {
  padding-bottom: 2ex;
}

.stop-list {
  display: table;
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  list-style: none;
}

.stop-list > li {
  display: table-row;
}

.stop-list__name,
.stop-list__connections {
  display: table-cell;
  padding: 1rem 0;
  border-top: thin solid var(--border);
  vertical-align: middle;
}

.stop-list__name {
  width: 50%;
}

.stop-list__connections {
  font-size: 1rem;
}

.stop-heading,
.departure-row {
  display: flex;
  flex-wrap: wrap;
  margin-right: -.75rem;
  margin-bottom: 20px;
  margin-left: -.75rem;
}

.stop-heading > *,
.departure-row > * {
  min-height: 1px;
  padding: 0 .75rem;
}

.stop-heading__title {
  width: 83.33333%;
}

.stop-heading__action {
  width: 16.66667%;
  text-align: right;
}

.stop-heading__fullscreen {
  float: right;
  font-size: 60%;
}

.departure-route {
  width: 100%;
}

.departure-route__inner {
  display: flex;
  margin-right: -.75rem;
  margin-left: -.75rem;
}

.departure-route__line,
.departure-route__description {
  min-height: 1px;
  padding: 0 .75rem;
}

.departure-route__line {
  width: 16.66667%;
}

.departure-route__description {
  width: 83.33333%;
}

.departure-times {
  width: 75%;
  text-align: right;
}

.departure-action {
  width: 25%;
  text-align: right;
}

.space {
  margin: 10px;
}

.passe {
  color: var(--muted-text);
}

.phone-route {
  position: relative;
}

.phone-route::after {
  position: absolute;
  top: -10px;
  right: -10px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  color: #000;
  background: #fff;
  box-shadow: 0 0 1px #333;
  content: "\e0cd";
  font-family: "Material Icons";
  font-size: .6em;
  font-weight: 400;
  line-height: 18px;
  text-align: center;
  text-transform: none;
}

.schedule-card {
  display: inline-block;
  padding: 1px;
  margin: 10px;
  background: var(--raised-surface);
  box-shadow: 2px 2px 5px 0 var(--shadow);
  font-size: 3.1vmax;
}

.schedule-later {
  font-size: 1.4vmax;
}

.is-imminent {
  animation: blink 1.35s ease-in-out infinite;
}

@keyframes blink {
  50% { opacity: 0; }
}

.notice {
  width: 100%;
  padding: .75rem;
  text-align: center;
}

.notice--warning {
  border-left: 4px solid #ff9800;
  background: var(--warning-background);
}

.notice--alert {
  border-left: 4px solid var(--danger);
  background: var(--alert-background);
}

.refresh-control {
  position: fixed;
  z-index: 997;
  right: 23px;
  bottom: 23px;
  padding-top: 15px;
}

.refresh-button {
  position: relative;
  z-index: 1;
  display: inline-flex;
  width: 56px;
  height: 56px;
  align-items: center;
  justify-content: center;
  padding: 0;
  overflow: hidden;
  border-radius: 50%;
  color: #fff;
  background: var(--danger);
  line-height: 56px;
  vertical-align: middle;
}

.refresh-button:hover,
.refresh-button:focus-visible {
  color: #fff;
  filter: brightness(1.08);
}

.refresh-timer {
  position: fixed;
  right: 19px;
  bottom: -31px;
  margin-bottom: 0;
  pointer-events: none;
}

.refresh-timer svg {
  display: block;
  width: 65px;
  margin: 50px auto;
  border-radius: 100%;
  background: var(--danger);
}

.refresh-timer__progress {
  fill: none;
  stroke: #fff;
  stroke-width: 10;
  stroke-linecap: round;
  stroke-dasharray: 785;
  stroke-dashoffset: 785;
  animation: refresh-progress 30s linear forwards;
}

@keyframes refresh-progress {
  to { stroke-dashoffset: 0; }
}

.fullscreen-page {
  min-height: 100vh;
  text-align: center;
}

.fullscreen-page .dans,
.fullscreen-page .ilya,
.fullscreen-page .clock-time {
  font-size: 70%;
}

.fullscreen-page__schedules {
  text-align: center;
}

.fullscreen-page__footer {
  text-align: center;
}

@media only screen and (min-width: 601px) {
  .topbar,
  .menu-toggle,
  .menu-toggle .app-icon {
    height: 64px;
    line-height: 64px;
  }

  .line-list__item {
    grid-column: span 2;
  }

  .line-list--detailed .line-list__item {
    grid-column: span 4;
  }

  .departure-route,
  .departure-times {
    width: 41.66667%;
  }

  .departure-action {
    width: 16.66667%;
  }
}

@media only screen and (min-width: 993px) {
  html { font-size: 14.5px; }

  .line-list__item {
    grid-column: span 1;
  }
}

@media only screen and (min-width: 1201px) {
  html { font-size: 15px; }
}

@media only screen and (max-width: 992px) {
  body.menu-open {
    overflow: hidden;
  }

  .site-header,
  .site-footer {
    padding-left: 0;
  }

  .site-main {
    padding-left: 1em;
  }

  .site-menu {
    transform: translateX(-105%);
  }

  .site-menu.is-open {
    transform: translateX(0);
  }

  .menu-overlay.is-open {
    display: block;
  }

  .menu-toggle {
    display: block;
  }
}

@media only screen and (max-width: 600px) {
  .hide-phone {
    display: none !important;
  }

  .station {
    text-align: center;
  }

  .mobile-separator {
    display: block;
  }
}

@media only screen and (min-width: 601px) {
  .mobile-separator {
    display: none;
  }
}

@media only screen and (max-width: 992px) {
  .hide-tablet-down {
    display: none !important;
  }
}

@media screen and (max-width: 39.9375em) and (orientation: portrait) {
  .schedule-card {
    min-width: 90%;
    margin: 4px;
    box-shadow: 1px 1px 3px 0 var(--shadow);
  }

  .schedule-later {
    font-size: 2.8vmax;
  }
}

@media screen and (max-width: 39.9375em) and (orientation: landscape) {
  .schedule-card {
    min-width: 45%;
    margin: 4px;
    box-shadow: 1px 1px 3px 0 var(--shadow);
  }
}

@media screen and (min-width: 40em) {
  .schedule-card {
    min-width: 3%;
    font-size: 3.5vmax;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}

.comparison-header h1 {
  margin-bottom: .4rem;
}

.comparison-form {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: .8rem;
}

.comparison-form label {
  display: grid;
  gap: .25rem;
}

.comparison-form input {
  min-width: 10rem;
  padding: .55rem .65rem;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 4px;
}

.comparison {
  display: block;
}

.comparison-context,
.comparison-summary {
  margin: .75rem 0;
  padding: .75rem 1rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 4px;
}

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

.comparison-panel {
  min-width: 0;
  padding: 1rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 4px;
}

.comparison-panel h2 {
  margin-top: 0;
}

.comparison-passage {
  display: grid;
  grid-template-columns: minmax(6rem, auto) 1fr;
  gap: .8rem;
  padding: .7rem 0;
  border-top: 1px solid var(--border);
}

.comparison-passage--unusual {
  margin-inline: -.5rem;
  padding-inline: .5rem;
  background: color-mix(in srgb, #f59e0b 18%, transparent);
}

.comparison-passage__time {
  white-space: nowrap;
}

@media only screen and (max-width: 760px) {
  .comparison-grid {
    grid-template-columns: 1fr;
  }
}

.anomaly-updated {
  color: var(--muted-text);
  font-size: .9em;
}

.anomaly-freshness {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: .75rem;
  margin: 1rem 0;
}

.anomaly-freshness__item {
  padding: .7rem .9rem;
  background: var(--raised-surface);
  border-left: 4px solid var(--action);
  border-radius: 2px;
}

.anomaly-freshness__item--stale {
  border-left-color: var(--danger);
}

.anomaly-group {
  border-top: 1px solid var(--divider);
}

.anomaly-group h2 {
  font-size: 1.6em;
}

.anomaly-count {
  display: inline-block;
  min-width: 1.7em;
  padding: .05em .45em;
  border-radius: 1em;
  color: #fff;
  background: var(--navigation);
  font-size: .55em;
  line-height: 1.5;
  text-align: center;
  vertical-align: middle;
}

.anomaly-list {
  padding-left: 1.4em;
}

.anomaly-list li + li {
  margin-top: .45em;
}

.anomaly-group--upcoming {
  background: var(--warning-background);
  padding-inline: 1rem;
}

.anomaly-method {
  color: var(--muted-text);
  border-top: 1px solid var(--divider);
  font-size: .9em;
}

@media only screen and (max-width: 600px) {
  .anomaly-freshness {
    grid-template-columns: 1fr;
  }
}
