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

html,
body {
  min-height: 100%;
}

body {
  font-family: 'Cantarell', sans-serif;
  background: #1e1d20;
  color: #d8d1e4;
  min-height: 100vh;
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding: 32px 24px 104px;
}

.container {
  width: 100%;
}

.screen {
  width: 100%;
  max-width: 980px;
  display: grid;
  justify-items: center;
  gap: 30px;
  text-align: center;
  margin: 0 auto;
}

.question {
  color: #d8d1e4;
  font-size: clamp(2rem, 4.2vw, 3.4rem);
  line-height: 1.15;
  font-weight: 400;
  letter-spacing: 0.01em;
  transition: opacity 0.28s ease, transform 0.28s ease;
  min-height: 1.25em;
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: 20ch;
}

.question.is-loading {
  opacity: 0;
  transform: translateY(10px);
}

.question.is-complete {
  color: #b1abbd;
  font-size: clamp(1.35rem, 2.6vw, 1.95rem);
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  max-width: none;
  opacity: 0.92;
}

button {
  position: fixed;
  left: 50%;
  bottom: calc(88px + env(safe-area-inset-bottom));
  transform: translateX(-50%) scale(1);
  appearance: none;
  border: 0;
  background: #6f628f;
  color: #eae6f4;
  border-radius: 999px;
  padding: 0.92rem 1.5rem;
  font-size: 0.96rem;
  font-weight: 500;
  cursor: pointer;
  transition:
    background-color 220ms cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 220ms cubic-bezier(0.22, 1, 0.36, 1),
    opacity 220ms cubic-bezier(0.22, 1, 0.36, 1),
    transform 220ms cubic-bezier(0.22, 1, 0.36, 1);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.18);
  touch-action: manipulation;
}

button.is-pulsing {
  animation: button-pop 260ms ease-out;
}

@media (max-width: 640px) {
  body {
    padding: 20px 16px 88px;
  }

  .question {
    font-size: clamp(1.8rem, 7vw, 2.8rem);
  }

  button {
    bottom: calc(40px + env(safe-area-inset-bottom));
    padding: 0.88rem 1.35rem;
  }
}

button:hover {
  background: #7b6d9d;
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.2);
  transform: translateX(-50%) scale(1.03);
}

button:disabled {
  cursor: wait;
  opacity: 0.82;
}

button.is-hidden {
  display: none;
}

button:focus-visible {
  outline: 3px solid rgba(239, 237, 246, 0.32);
  outline-offset: 4px;
}

@keyframes button-pop {
  0% {
    transform: translateX(-50%) scale(1);
  }
  45% {
    transform: translateX(-50%) scale(1.08);
  }
  100% {
    transform: translateX(-50%) scale(1);
  }
}
