:root {
  --primary-color: #412eab;
  --secondary-color: #0d0b1f;
  --highlight-color: #0d0b1f;
  --light-color: #a8a8a8;
  --primary-textColor: rgba(255, 255, 255, 0.87);

  --cool-box-shadow: inset 0 0 5px #fff, inset 2px 0 8px var(--primary-color),
    inset -2px 0 8px var(--primary-color), inset 2px 0 30px var(--primary-color),
    inset -2px 0 30px var(--primary-color), 0 0 10px #fff,
    -2px 0 8px var(--primary-color), 2px 0 8px var(--primary-color);
}

body {
  margin: 0;
  font-family: "Playfair Display", serif;
  line-height: 1.5;
  cursor: help;
  background-color: #121212;
}

h1,
h2,
h3,
button {
  color: var(--primary-textColor);
}

.glowText {
  animation: glow 1s ease-in-out infinite alternate;
}

p,
pre {
  color: var(--primary-textColor);
  font-size: 16px;
  font-family: Helvetica Neue, san-serif;
}

pre {
  font-size: 20px;
}

canvas {
  width: 100vw;
  height: 100vh;
  display: block;
  position: fixed;
  z-index: -1;
  top: 0;
  left: 0;
}

.icon {
  font-size: 1.5rem;
  color: var(--light-color);
  position: fixed;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  margin: 0;
  z-index: 100;
}

#about-btn,
#closeButton,
#closePopup {
  right: 24px;
  top: 24px;
}

#audioToggle {
  display: none;
}

#intro {
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  height: 100vh;
  width: 100vw;
}

#intro h1 {
  width: 50vw;
  font-size: 2em;
  text-align: center;
}

#aboutContainer h2 {
  margin-top: 2.5em;
  margin-bottom: 0;
}

#aboutContainer a {
  text-decoration: underline;
}

#main_container {
  opacity: 0;
  transition: opacity 2s;
}

a {
  color: var(--primary-textColor);
  text-decoration: none;
}

a:hover {
  cursor: pointer;
}

.glow {
  animation: glow 1s ease-in-out infinite alternate;
}

@keyframes glow {
  from {
    text-shadow: 0 0 1px #fff, 0 0 4px #fff, 0 0 10px var(--primary-color),
      0 0 10px var(--primary-color), 0 0 10px var(--primary-color),
      0 0 15px var(--primary-color), 0 0 60px var(--primary-color);
  }

  to {
    text-shadow: 0 0 1px #fff, 0 0 4px var(--secondary-color),
      0 0 10px var(--secondary-color), 0 0 10px var(--secondary-color),
      0 0 10px var(--secondary-color), 0 0 15px var(--secondary-color),
      0 0 60px var(--secondary-color);
  }
}

@keyframes glowBig {
  from {
    text-shadow: 0 0 1px #fff, 0 0 4px #fff, 0 0 10px var(--primary-color),
      0 0 10px var(--primary-color), 0 0 10px var(--primary-color),
      0 0 15px var(--primary-color), 0 0 120px var(--primary-color);
  }

  to {
    text-shadow: 0 0 1px #fff, 0 0 4px var(--secondary-color),
      0 0 10px var(--secondary-color), 0 0 10px var(--secondary-color),
      0 0 10px var(--secondary-color), 0 0 15px var(--secondary-color),
      0 0 120px var(--secondary-color);
  }
}

#left {
  padding: 5vw;
  padding-bottom: 5vh;
  width: 90vw;
  transition: width 1s;
  height: calc(100vh - 16px);
  position: fixed;
}

#textContainer {
  width: 40vw;
  margin-top: 20px;
  padding-bottom: 20px;
  height: calc(70vh - 32px);
  overflow-y: scroll;
}

#right {
  opacity: 0;
  transition: opacity 2s;
  padding: 5vw;
  width: 40vw;
  margin-left: 50vw;
  display: flex;
  flex-direction: column;
}

#witchText {
  border: none;
  margin-top: 35px;
  line-height: 1.5;
  width: 30vw;
  height: 300px;
  background-color: transparent;
  color: var(--primary-textColor);
  text-shadow: 1px 1px 5px var(--primary-color);
  font-size: 20px;
  padding: 1em;
  box-shadow: 0px 0px 30px var(--primary-color);
  z-index: 100;
}

#witchText:focus {
  outline: none;
  box-shadow: var(--cool-box-shadow);
}

#castSpellButton {
  background-color: transparent;
  border: none;
  box-shadow: 0px 0px 30px var(--primary-color);
  margin-top: 3em;
  height: 3em;
  width: 10em;
  border-radius: 0.86em;
  z-index: 3;
}

#saveButton {
  position: fixed;
  right: 60px;
  top: 24px;
  position: fixed;
}

.specialButton {
  border: none;
  background-color: transparent;
  box-shadow: 0px 0px 30px var(--primary-color);
  padding: 0.8em;
  margin-right: 1em;
  border-radius: 0.86em;
  animation: glow 1s ease-in-out infinite alternate;
}

.active-button {
  box-shadow: var(--cool-box-shadow);
}

pre {
  white-space: pre-wrap;
}

#spell {
  font-family: "Playfair Display", serif;
  font-size: 14px;
  padding: 2.5em;
}

#responsePopup {
  position: relative;
  z-index: 1;
  overflow: scroll;
  display: none;
  margin: 10% auto;
  width: 50%;
  height: 60%;
}

/* Floating buttons just above the spell box */
#closePopup,
#saveButton {
  position: fixed;
  z-index: 1002;
  opacity: 0;
  transition: opacity 9s;
  transition-delay: 5s;
}

.visible {
  opacity: 1;
  border: 1px solid red;
}

#closePopup {
  right: 24px;
}

#saveButton {
  right: calc(24px + 40px);
}

#popup-content {
  padding: 10px;
}

.show {
  display: block;
}

#aboutContainer {
  padding: 15vw;
  padding-top: 4vw;
  display: none;
}

#spellTitle {
  font-style: italic;
}
