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

body {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

.container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
}

.ball-container {
  position: relative;
  width: 200px;
  height: 200px;
}

#ball {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, #1a1a1a, #000);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5), inset -2px -2px 10px rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  animation: breathe 4s ease-in-out infinite;
}

@keyframes breathe {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.02);
  }
}

#ball.shake {
  animation: shake 0.6s ease-in-out;
}

@keyframes shake {
  0%, 100% {
    transform: translate(0, 0) rotate(0deg);
  }
  10% {
    transform: translate(-3px, -3px) rotate(-2deg);
  }
  20% {
    transform: translate(3px, 3px) rotate(2deg);
  }
  30% {
    transform: translate(-3px, 3px) rotate(-2deg);
  }
  40% {
    transform: translate(3px, -3px) rotate(2deg);
  }
  50% {
    transform: translate(-2px, -2px) rotate(-1deg);
  }
  60% {
    transform: translate(2px, 2px) rotate(1deg);
  }
  70% {
    transform: translate(-2px, 2px) rotate(-1deg);
  }
  80% {
    transform: translate(2px, -2px) rotate(1deg);
  }
  90% {
    transform: translate(-1px, -1px) rotate(0deg);
  }
}

.triangle-window {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 0;
  height: 0;
  border-left: 40px solid transparent;
  border-right: 40px solid transparent;
  border-bottom: 70px solid;
  border-bottom-color: #667eea;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  clip-path: polygon(0% 100%, 50% 0%, 100% 100%);
  width: 80px;
  height: 70px;
}

#response-window {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 60px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: #fff;
  font-size: 16px;
  font-weight: 600;
  text-transform: uppercase;
  opacity: 0;
  transition: opacity 0.6s ease-in;
  line-height: 1.2;
}

#response-window.show {
  opacity: 1;
}

#ask-button {
  padding: 12px 32px;
  font-size: 16px;
  font-weight: 600;
  border: none;
  border-radius: 8px;
  background: #fff;
  color: #667eea;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

#ask-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4), 0 0 20px rgba(102, 126, 234, 0.3);
}

#ask-button:active {
  transform: translateY(0);
}

@media (max-width: 480px) {
  .ball-container {
    width: 160px;
    height: 160px;
  }

  .triangle-window {
    clip-path: polygon(0% 100%, 50% 0%, 100% 100%);
    width: 60px;
    height: 50px;
  }

  #response-window {
    width: 50px;
    height: 50px;
    font-size: 9px;
  }

  #ask-button {
    padding: 10px 24px;
    font-size: 14px;
  }
}
