body {
  display: flex;
  flex-direction: column;
  margin: 0;
  height: 100vh;
  width: 100vw;
  background: hsl(0, 0%, 0%);
  font-family: sans-serif;
  touch-action: none;
}

main {
  display: flex;
  flex-grow: 1;
  color: hsl(0, 0%, 100%);
}

footer {
  font-size: 60%;
  text-align: right;
  flex-shrink: 0;
  margin: 1ex;
}

a {
  color: hsl(35, 80%, 30%);
  text-decoration: none;
}

/* Horizontal layout */
@media (min-aspect-ratio: 1/1) {
  :root {
    font-size: clamp(1rem, 3vw, 2rem);
  }

  main {
    flex-direction: row;
  }
}

/* Vertical layout */
@media (max-aspect-ratio: 1/1) {
  :root {
    font-size: clamp(1rem, 3vh, 2rem);
  }

  main {
    flex-direction: column;
  }
}

button {
  color: hsl(0, 0%, 100%);
  font-size: inherit;
  display: flex;
  flex: 1;
  justify-content: center;
  align-items: center;
  padding: 0ex;
  margin: 0.3ex;
  border-style: solid;
  border-width: 0.5ex;
  border-radius: 2.0ex;
}

button:active {
  border-color: hsl(35, 80%, 80%) !important;
}

.column {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.row {
  display: flex;
  flex-direction: row;
  flex: 1;
}

.display {
  display: flex;
  flex-direction: row;
  flex: 2;
}

.digit {
  display: flex;
  flex: 1;
  justify-content: center;
  align-items: center;
  font-size: 500%;
  font-variant-numeric: tabular-nums;
  color: hsl(0, 0%, 100%);
}

.digit.selected {
  color: hsl(35, 80%, 60%);
}

.bar {
  display: none;
}

.bar.selected {
  display: flex;
}

.num {
  background-color: hsl(35, 0%, 20%);
  border-color: hsl(35, 0%, 20%);
}

.fun {
  background-color: hsl(35, 80%, 60%);
  border-color: hsl(35, 80%, 60%);
}

.sig {
  background-color: hsl(35, 80%, 60%);
  border-color: hsl(35, 80%, 60%);
}

.play.locked {
  background-color: hsl(112, 80%, 30%);
  border-color: hsl(112, 80%, 30%);
}

.tick.off {
  background-color: hsl(35, 0%, 20%);
  border-color: hsl(35, 0%, 20%);
}

.tick.low {
  background-color: hsl(35, 80%, 30%);
  border-color: hsl(35, 80%, 30%);
}

.tick.high {
  background-color: hsl(35, 80%, 60%);
  border-color: hsl(35, 80%, 60%);
}

.tick.current.off {
  border-color: hsl(35, 0%, 40%);
}

.tick.current.low {
  border-color: hsl(35, 80%, 60%);
}

.tick.current.high {
  border-color: hsl(35, 80%, 80%);
}

.tick.left {
  border-radius: 2ex 0ex 0ex 2ex;
}

.tick.center {
  border-radius: 0ex;
}

.tick.right {
  border-radius: 0ex 2ex 2ex 0ex;
}

.stack {
  display: inline-block;
  text-align: center;
  vertical-align: middle;
}

.stack>.top {
  display: block;
  border-bottom: 2px solid white;
}

.stack>.bot {
  display: block;
}