* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
body, html {
  height: 100%;
  overflow: hidden;
  font-family: 'Orbitron', sans-serif;
  background: black;
  color: #d0cfff;
}
canvas#matrix-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -2;
}
.enter-code-btn {
  position: absolute;
  top: 20px;
  right: 20px;
  background: #111;
  border: 2px solid #7700ff;
  color: #d0cfff;
  font-size: 1.5rem;
  padding: 10px;
  border-radius: 50%;
  cursor: pointer;
  z-index: 3;
  transition: 0.3s;
}
.enter-code-btn:hover {
  background: #7700ff;
  color: #000;
}
.content {
  position: relative;
  padding: 20px;
  z-index: 1;
}
.glitch {
  font-size: 3rem;
  color: #d0cfff;
  text-shadow: 0 0 10px #7700ff, 0 0 20px #00f0ff;
  animation: glitch 1s infinite alternate;
  text-align: center;
}
@keyframes glitch {
  from {
    text-shadow: 2px 0 #ff00dd, -2px 0 #00ffff;
  }
  to {
    text-shadow: -2px 0 #ff00dd, 2px 0 #00ffff;
  }
}
.fade-in {
  opacity: 0;
  animation: fadeIn 2s ease-in forwards;
}
@keyframes fadeIn {
  to {
    opacity: 1;
  }
}
.editor-container {
  display: grid;
  gap: 10px;
  margin-top: 20px;
}
@media (min-width: 768px) {
  .editor-container {
    grid-template-columns: repeat(3, 1fr);
  }
}
.CodeMirror {
  height: 200px;
  border: 2px solid #7700ff;
  box-shadow: 0 0 10px #7700ff;
}
.buttons {
  text-align: center;
  margin: 20px 0;
}
.buttons button {
  margin: 5px;
  padding: 10px;
  background: #111;
  border: 2px solid #7700ff;
  color: #d0cfff;
  cursor: pointer;
  transition: 0.3s;
}
.buttons button:hover {
  background: #7700ff;
  color: #000;
}
.preview {
  width: 90%;
  max-width: 100%;
  height: 400px;
  display: block;
  margin: 0 auto;
  border: 2px solid #00f0ff;
  box-shadow: 0 0 10px #00f0ff;
}

/* Phones: stack editors and shrink preview */
@media (max-width: 768px) {
  .editor-container {
    grid-template-columns: 1fr;
  }
  .preview {
    height: 300px;
  }
}

/* Very small phones */
@media (max-width: 480px) {
  .buttons button {
    font-size: 0.8rem;
    padding: 8px;
  }
  .enter-code-btn {
    top: 10px;
    right: 10px;
    font-size: 1rem;
    padding: 6px;
  }
}
