/* Общие стили */
body {
  margin: 0;
  padding: 0;
  background: black;
  color: white;
  font-family: "Courier New", Courier, monospace;
  font-weight: 300;
  text-align: center;
  user-select: none;
  overflow: hidden; /* ⚡ ИЗМЕНЕНО: Скрываем всю прокрутку, чтобы избежать "дёргания" */
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
}

/* Заголовок END */
#end-title {
  font-size: 12vw;
  font-weight: 300;
  letter-spacing: 1rem;
  text-shadow: 0 0 20px rgba(255, 255, 255, 0.15);
  margin: 0;
  position: relative;
  text-align: center;
  width: fit-content;
}

.cursor {
  position: absolute;
  top: 0;
  right: -0.5em;
  animation: blink 1s infinite step-end alternate;
}

@keyframes blink {
  50% {
    opacity: 0;
  }
}

/* Сообщения */
.floating-message {
  position: absolute;
  color: rgba(200, 200, 200, 0.7);
  font-size: 1.3rem;
  font-weight: 300;
  font-family: "Courier New", Courier, monospace;
  opacity: 0;
  transform: scale(0.8);
  animation: fly-forward 10s forwards linear;
  pointer-events: none;
  text-shadow: 0 0 12px rgba(255, 255, 255, 0.2);
  mix-blend-mode: difference;
}

@keyframes fly-forward {
  0% {
    opacity: 0;
    transform: scale(0.8);
  }
  10% {
    opacity: 1;
    transform: scale(1);
  }
  100% {
    opacity: 0;
    transform: scale(3);
  }
}

/* Ввод */
#input-section {
  margin-top: 5vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  /* ⚡ НОВОЕ: Добавляем отступ снизу, чтобы отделить от кнопки "Поддержать" */
  margin-bottom: 10px;
}

#input-section label {
  display: block;
  margin-bottom: 10px;
  font-size: 1rem;
  color: rgba(255, 255, 255, 0.8);
}

#message-input {
  width: 300px;
  padding: 10px;
  background: black;
  border: none;
  border-bottom: 2px solid white;
  color: white;
  font-size: 1rem;
  font-family: "Courier New", Courier, monospace;
  outline: none;
  caret-color: white;
  letter-spacing: 0.05rem;
  text-align: center;
}

#message-input::placeholder {
  color: rgba(255, 255, 255, 0.4);
  text-align: center;
}

/* Кнопки */
#send-btn,
.donate-btn {
  /* ⚡ УДАЛЕНО: margin-top: 15px; */
  padding: 8px 14px;
  background: transparent;
  border: 1px solid white;
  border-radius: 8px;
  color: white;
  font-size: 1rem;
  font-family: "Courier New", Courier, monospace;
  font-weight: 300;
  cursor: pointer;
  transition: 0.3s;
  text-decoration: none;
}

#send-btn:hover,
.donate-btn:hover {
  background: white;
  color: black;
}

/* Футер с кнопками */
footer {
  margin-top: 5vh;
  width: 100%;
}

.footer-buttons {
  display: flex;
  justify-content: center;
  align-items: center; /* ⚡ НОВОЕ: Выравниваем кнопку по центру */
  gap: 20px;
  flex-direction: column; /* ⚡ ИЗМЕНЕНО: На всех устройствах кнопки будут друг под другом */
}

/* Медиазапросы для адаптивности */
@media screen and (max-width: 768px) {
  #end-title {
    font-size: calc(15vw * 1.5); /* ⚡ УВЕЛИЧЕНО на 20% */
    letter-spacing: calc(0.5rem * 1.5);
  }
  
  .cursor {
    font-size: calc(15vw * 1.5);
    right: -0.75em;
  }

  .floating-message {
    font-size: calc(1rem * 1.5); /* ⚡ УВЕЛИЧЕНО на 20% */
  }

  #message-input {
    width: calc(250px * 1.5); /* ⚡ УВЕЛИЧЕНО на 20% */
  }
  
  #send-btn,
  .donate-btn {
    font-size: calc(0.9rem * 1.5); /* ⚡ УВЕЛИЧЕНО на 20% */
    padding: calc(6px * 1.5) calc(12px * 1.5);
  }
  
  .footer-buttons {
    gap: calc(10px * 1.5);
  }
}

/* Для планшетов (ширина экрана от 769px до 1024px) */
@media screen and (min-width: 769px) and (max-width: 1024px) {
  #end-title {
    font-size: 10vw;
  }
  
  .cursor {
    font-size: 10vw;
    right: -0.75em;
  }
}