* { 
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: system-ui, sans-serif;
}

:root {
  --toLineLeft: -44px;
}

body {
    background-color: #f1f1f1;
    /* background-color: #fff; */
}

h2 {
    color: #333;
}

.spectrum-container {
    position: absolute;
    /* right: 10vh; */
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: space-around;
    align-items: center;
    top: 0vh;
    right: 10vw;
}

.background{
  position: relative;
  /* top: 10vh; */
  /* left: 40vw; */
  /* right: calc(-90vw + 4rem); */
  width: 40px;
  height: 75vh;
  background: #111;
  border: .25rem solid #333;
  border-radius: 1rem;
  overflow: hidden;
}

.spectral-line{
  position: absolute;
  left: 0;
  width: 100%;
  height: 18px;
  pointer-events: none;
  transition: .2s ease-out;
}

.spectral-line::before,
.spectral-mid::before,
.spectral-inner::before{
  content: "";
  position: absolute;
  left: 0;
  width: 100%;
}

.spectral-line::before{
  height: 18px;
  filter: blur(12px);
  background: var(--outer, #1221ae);
}

.spectral-mid{ position: relative; }
.spectral-mid::before{
  height: 4px;
  filter: blur(4px);
  background: var(--mid, #34a0de);
}

.spectral-inner{ position: relative; }
.spectral-inner::before{
  height: 3px;
  filter: blur(1.75px);
  background: var(--inner, #e9faff);
}

.line-container {
    margin-left: 10vw;
    height: 100vh;
    width: 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative; /* needed for absolute positioning of lines */
}

.ball {
    position: absolute;
    background-color: #999;
    width: 40px;
    height: 3px;
    border-radius: 3px;
    left: var(--toLineLeft);
    /* left: 13.5px; */
    /* top: 200px; */
    cursor: grab;
    z-index: 2;
}

.ball::before{
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 28px;          /* hitbox size – tweak */
  height: 30px;
  transform: translate(-50%, -50%);
  /* background: rgba(255,0,0,.1);  // debug */
  cursor: grab;         /* keeps the same cursor on the hitbox */
}

.line {
    width: 100%;
    height: 3px;
    border-radius: 1.5px;
    background-color: #999;
    position: absolute;
    left: 0;
    font-size: x-small;
    cursor: pointer;
    transition: .15s ease-in;
    z-index: 2;
}

.line::after {
  content: "n = " attr(data-n);
  position: absolute;
  left: calc(100% + 8px);    /* push outside */
  top: 50%;
  transform: translateY(-50%);
  white-space: nowrap;
  /* pointer-events: none; */
  font: 12px/1.2 system-ui, sans-serif;
  color: #555;
}

.line:hover {
    background-color: #80f112 !important;
}


#svg-container {
  position: absolute;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  pointer-events: none;
}

.wave-svg {
  width: 100vw;
  height: auto;
  max-height: 100vh;
  z-index: -1;
}

/* .wave-svg path {
  stroke-width: 4;
} */

.wl-text-container {
  pointer-events: none;
  position: absolute;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column-reverse;
}

.wl-text {
  transition: .5s ease-in;
}

.hidden {
  opacity: 0;
}

#toLine {
  height: 100vh;
  width: 40px;
  /* border: 1px solid; */
  position: absolute;
  top: 0vh;
  left: calc(10vw + var(--toLineLeft));
  /* left: 10vw; */
}

#toLine line {
  stroke: #999;
  stroke-opacity: 0;
  vector-effect: non-scaling-stroke;
  stroke-width: 3px;
  stroke-linecap: round;
}

#toLine polyline {
  stroke: #999;
  stroke-opacity: 0;
  vector-effect: non-scaling-stroke;
  stroke-width: 3px;
  stroke-linecap: round;
  pointer-events: none;
}