* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  color: white;
  font-family: Arial, Helvetica, sans-serif;
}

html, body {
  height: 100%;
  width: 100%;
}

main {
  height: 100%;
  width: 100%;
  background-color: black;
  display: flex;
  justify-content: center;
  align-items: center;
}

.piano {
  position: absolute;
  bottom: 0;
  width: 100%;
  height: 220px;
  display: flex;
  justify-content: center;
  padding: 10px;
  align-items: center;
  gap: 2px;
}

.keys {
  height: 100%;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 2px;
}

.written{
    opacity: 0;
    font-size: 2rem;
    transition: all linear 0.2s;
}

/* White keys */
.white {
  height: 100%;
  width: 70px;
  background-color: #f3f3f2;
  border-radius: 0.5rem;
  overflow: hidden;
  position: relative;
  color: black;
  font-size: 1.5rem;
}

/* White key highlight activated by JS */
.white.active::after {
    content: "";
    position: absolute;
    inset: 0;
    background: #6ebdf4;
    opacity: 0.4;
}

/* Black keys */
.black {
    height: 70%;
    width: 40px;
    background-color: black;
    border-radius: 0.5rem;
    position: absolute;
    top: 0;
    z-index: 1;
    font-size: 1.5rem;
  cursor: pointer;
  overflow: hidden;
  color: white;
}

/* Black key highlight activated by JS */
.black.active::after {
  content: "";
  position: absolute;
  inset: 0;
  background: #6ebdf4;
  opacity: 0.5;
}

/* Positioning black keys */
.one { left: 25%; }
.two { right: 25%; }
.three { left: 18%; }
.five { right: 18%; }
