@font-face {
  font-family: "VCR_OSD_MONO";
  src: url("./fonts/VCR_OSD_MONO.ttf") format("truetype");
  font-weight: normal;
  font-style: normal;
}

:root {
  --main-bg-color: oklch(0.1471 0.035 220.43);
  --accent-color: oklch(0.8724 0.1932 188.01);

  --flow-space: 1em;

  --step--2: clamp(0.7813rem, 0.7555rem + 0.1144vw, 0.8442rem);
  --step--1: clamp(0.9375rem, 0.8607rem + 0.3414vw, 1.1253rem);
  --step-0: clamp(1.125rem, 0.9716rem + 0.6818vw, 1.5rem);
  --step-1: clamp(1.35rem, 1.0843rem + 1.1809vw, 1.9995rem);
  --step-2: clamp(1.62rem, 1.1924rem + 1.9006vw, 2.6653rem);
  --step-3: clamp(1.944rem, 1.2858rem + 2.9253vw, 3.5529rem);
  --step-4: clamp(2.3328rem, 1.3497rem + 4.3695vw, 4.736rem);
  --step-5: clamp(2.7994rem, 1.3619rem + 6.3886vw, 6.3131rem);

  --wrapper-width: clamp(16rem, 93vw, 85rem);
  --gutter: var(--space-s-m, 1rem);
}

body,
h1,
h2,
h3,
h4,
p,
figure,
blockquote,
dl,
dd {
  margin: 0;
}

html {
  background: var(--main-bg-color);

  html:focus-within {
    scroll-behavior: smooth;
  }
}

.wrapper {
  width: var(--wrapper-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--gutter);
  padding-right: var(--gutter);
  position: relative;
}

.skip-app-link {
  position: absolute;
  top: 0;
  left: 0;
  background: var(--accent-color);
  font-size: var(--step-0);
  padding: 0.5rem 1.5rem;
  transform: translateY(-120%);

  &:focus {
    transform: translateY(0);
  }
}

#apology {
  font-size: var(--step-1);
  margin-bottom: 7rem;
}

.info {
  margin-top: 1em;
}

.flow > * + * {
  margin-top: var(--flow-space, 1em);
}

body {
  background: var(--main-bg-color);
  color: #fff;
  font-family: "VCR_OSD_MONO", monospace;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  text-align: center;
}

h1 {
  font-family: "VCR_OSD_MONO", monospace;
  font-size: var(--step-5);
  text-shadow: 0 0 5px var(--accent-color);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

p {
  font-size: var(--step--0);
}

button#start-btn {
  background: var(--accent-color);
  color: #000;
  border: none;
  border-radius: 12px;
  font-size: 1.2rem;
  padding: 0.8rem 1.6rem;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: 0 0 10px var(--accent-color);
}

button#start-btn:hover {
  background: var(--accent-color);
  box-shadow: 0 0 15px var(--accent-color);
}

.hidden {
  display: none;
}

#interface {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
}

.datepicker {
  display: flex;
  gap: 1rem;
  align-items: center;
  justify-content: center;
}

.column-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.2rem;
}

.column-label {
  font-size: 0.8rem;
  color: #aaa;
}

.column {
  height: 90px;
  width: 70px;
  overflow: hidden;
  border-radius: 10px;
  background: #222;
  box-shadow: inset 0 0 10px #000;
  position: relative;
}

.column.active {
  box-shadow: 0 0 15px var(--accent-color);
  border: 2px solid var(--accent-color);
}

.numbers {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  transition: transform 0.4s ease;
}

.numbers div {
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  color: #999;
}

.numbers div.active {
  color: var(--accent-color);
  font-weight: bold;
  font-size: 1.6rem;
}

.info {
  font-size: var(--step--0);
  opacity: 0.8;
}

.progress-bar {
  width: 200px;
  height: 10px;
  background: #333;
  border-radius: 5px;
  overflow: hidden;
}

.progress {
  height: 100%;
  background: limegreen;
  width: 0%;
  transition: width 0.1s;
}

.submitted {
  color: #00ff99;
  font-size: 1.3rem;
}

.tuner {
  position: relative;
  width: 600px;
  height: 30px;
  background: #222;
  border-radius: 8px;
  overflow: hidden;
}

.tuner-zone {
  position: absolute;
  top: 0;
  bottom: 0;
  opacity: 0.6;
}

.low {
  left: 0%;
  width: 25%;
  background: #ff5555;
}

.mid {
  left: 25%;
  width: 25%;
  background: #ffaa00;
}

.high {
  left: 50%;
  width: 25%;
  background: #55aaff;
}

.submit {
  left: 75%;
  width: 25%;
  background: #00ff99;
}

.needle {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 4px;
  background: #fff;
  border-radius: 2px;
  transition: left 0.1s ease-out;
}

.labels {
  width: 600px;
  display: flex;
  justify-content: space-between;
  font-size: var(--step--1);
  opacity: 0.7;
}

.footer {
  margin-top: 2em;

  p {
    font-size: var(--step--1);
    color: #aaa;

    a {
      color: var(--accent-color);
      text-decoration: none;

      svg {
        width: 1em;
        height: 1em;
        vertical-align: middle;
        path {
          fill: var(--accent-color);
        }
      }
    }
  }
}

@media (max-width: 700px) {
  .tuner,
  .labels {
    width: 90%;
  }

  h1 {
    text-shadow: none !important;
    transform: translate3d(0, 0, 0);
    backface-visibility: hidden;
  }
}
