*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  height: 100%;
  overflow: hidden;
  background: linear-gradient(160deg, #0a0a0a 0%, #1c1c1c 45%, #111 100%);
  font-family: "Courier New", Courier, monospace;
  color: #b0b0b0;
}

#stars {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

#parallax,
#word-layers {
  position: fixed;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

#parallax { z-index: 1; }
#word-layers { z-index: 2; }

.ship-layer {
  position: absolute;
  left: 0;
  width: 100%;
  height: 0;
  overflow: visible;
}

.ship-float {
  position: absolute;
  left: 0;
  filter: grayscale(1);
  user-select: none;
  will-change: transform;
}

.word-layer {
  position: absolute;
  left: 0;
  width: 100%;
  height: 0;
  overflow: visible;
}

.word-float {
  position: absolute;
  left: 0;
  font-size: clamp(1.8rem, 4.5vw, 4rem);
  font-weight: 300;
  letter-spacing: 0.12em;
  white-space: nowrap;
  opacity: 0.5;
  color: #909090;
  text-transform: lowercase;
  user-select: none;
  will-change: transform;
}

#prompt-area {
  position: fixed;
  left: 50%;
  top: 80%;
  transform: translate(-50%, -50%);
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hint {
  font-size: 10px;
  letter-spacing: 0.14em;
  color: #d8d8d8;
  opacity: 0.85;
  margin-bottom: 0.6rem;
  text-transform: lowercase;
  user-select: none;
}

#prompt {
  position: relative;
  display: flex;
  align-items: baseline;
  font-size: 80px;
  line-height: 1;
  color: #d0d0d0;
  white-space: pre;
  min-width: 12rem;
  min-height: 1em;
}

#prompt-input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: text;
  border: none;
  background: transparent;
  font-size: inherit;
  font-family: inherit;
}

#prompt-text {
  min-width: 0;
  pointer-events: none;
}

.cursor {
  display: inline-block;
  width: 3px;
  height: 0.85em;
  margin-left: 4px;
  background: linear-gradient(180deg, #bbb 0%, #666 100%);
  vertical-align: baseline;
  animation: blink 1s step-end infinite;
}

@keyframes scroll-left-once {
  from { transform: translateX(110vw); }
  to { transform: translateX(calc(-100% - 10vw)); }
}

@keyframes scroll-right-once {
  from { transform: translateX(calc(-100% - 10vw)); }
  to { transform: translateX(110vw); }
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}
