/* tools.runv.club: omni-tools in runv.club's clothes. the colours live in
   the MUI theme (omni-patch.py writes src/config/muiConfig.ts); this file
   has the rest: the club's terminal font, the devil and his moves.
   pictures are small and cached once; with reduced motion they stand still */

@font-face {
  font-family: "runv term";
  src: url(/runv/runv-term.woff2) format("woff2");
  font-display: swap;
}

/* the name in the bar, with the terminal's blinking cursor */
.runv-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: inherit;
  text-decoration: none;
}
.runv-brand img {
  width: 45px;
  height: 36px;
  image-rendering: pixelated;
  transition: transform .15s steps(2);
}
.runv-brand:hover img { transform: translateY(-3px) rotate(-6deg); }
.runv-word {
  font: 1.35rem/1 "runv term", "DejaVu Sans Mono", ui-monospace, monospace;
  letter-spacing: .02em;
  white-space: nowrap;
}
.runv-cur {
  display: inline-block;
  width: .6em;
  height: 1em;
  margin-left: .15em;
  vertical-align: -.12em;
  background: currentColor;
  animation: runv-blink 1s steps(1) infinite;
}
@keyframes runv-blink { 50% { opacity: 0; } }

/* the devil waving hello over the search box */
.runv-hero-devil img {
  width: 100px;
  height: 100px;
  image-rendering: pixelated;
}

/* asleep in the bottom corner on wide screens; he wakes up and waves while
   the pointer is on him. the empty div comes from omni-patch.py */
#runv-pet { display: none; }
@media (min-width: 80em) {
  #runv-pet {
    display: block;
    position: fixed;
    left: 16px;
    bottom: 8px;
    width: 80px;
    height: 80px;
    z-index: 5;
    background: url(/runv/pet-sleep.gif) center / 80px 80px no-repeat;
    image-rendering: pixelated;
  }
  #runv-pet:hover { background-image: url(/runv/pet-wave.gif); }
}

/* the loading dots: three blinking squares, like the cursor */
#spinner > div {
  border-radius: 0 !important;
  background-color: #8a84c4 !important;
}

@media (prefers-reduced-motion: reduce) {
  .runv-cur { animation: none; }
  .runv-brand img { transition: none; }
  .runv-brand:hover img { transform: none; }
  #runv-pet { background-image: url(/runv/pet-sleep.png); }
  #runv-pet:hover { background-image: url(/runv/pet-stand.png); }
  .MuiCard-root { transition: none !important; }
}
