/* Copyright Ayers Electronics Inc. All rights reserved. */
/* The marquee (js/marquee.js): one line along the bottom of the screen, above every layer but Night
   Mode's shade (css/player/night-mode.css), on its level's ground. It takes no press. */
:root {
  --marquee-h: calc(2 * var(--type-label));
}
#marquee {
  position: fixed;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 200;
  height: var(--marquee-h);
  padding: 0 var(--page-margin);
  overflow: hidden;
  white-space: nowrap;
  font-size: var(--type-label);
  line-height: var(--marquee-h);
  background: var(--scrim-soft);
  color: var(--on-scrim);
  border-top: 3px solid var(--history);
  pointer-events: none;
}
#marquee[data-level="warning"] {
  border-color: var(--error);
}
#marquee[data-level="alert"] {
  border-color: var(--live);
}
/* On the demo the marquee stands on the demo's bottom bar (css/components/demo-strip.css). */
body.demo #marquee {
  bottom: var(--demo-bar-height, 0px);
}
#marquee .marquee-words {
  display: inline-block;
}
/* The page under the marquee ends above it, so the Guide's last row stays in view. */
body.marquee-up #guide {
  padding-bottom: var(--marquee-h);
}
/* Rolling: the first pass starts in view, then the words cross from right to left. Declared
   only where motion is welcome; anywhere else the marquee stands still and pages. */
@media (prefers-reduced-motion: no-preference) {
  html:not([data-reduce-motion]) #marquee.rolling {
    padding: 0;
  }
  html:not([data-reduce-motion]) #marquee.rolling .marquee-words {
    padding-left: 100%;
    animation: marquee-roll var(--marquee-roll) linear infinite;
    animation-delay: var(--marquee-delay);
  }
}
@keyframes marquee-roll {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-100%);
  }
}
