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

body, html {
  height: 100%;
  margin: 0;
  font-family: 'Roboto', sans-serif;
  background-color: #ffffff;
  color: #333;
}

.container {
  max-width: 600px;
  margin: 0 auto;
  padding: 20px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

#initialContent, #fortuneResult {
  transition: opacity 0.5s ease;
}

.hide {
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
  transition: opacity 0.5s ease;
}

.show {
  opacity: 1;
  visibility: visible;
  transition: opacity 0.5s ease;
}

form {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

textarea {
  width: 100%;
  padding: 10px 15px;
  border: 1px solid #ccc;
  border-radius: 5px;
  font-size: 16px;
  font-family: 'Roboto', sans-serif;
  resize: none;
  overflow: hidden;
  min-height: 40px;
  transition: all 0.3s ease;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  background-color: #f9f9f9;
  margin-bottom: 15px; /* Add space below the textarea */
}

textarea:focus {
  outline: none;
  border-color: #007bff;
  box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.25);
}

button {
  background: linear-gradient(to bottom, #3a3a3a, #2a2a2a);
  color: white;
  border: 1px solid #000000;
  border-radius: 20px;
  padding: 8px 16px;
  font-size: 14px;
  font-weight: 400;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2),
              0 0 0 1px rgba(0, 0, 0, 0.1);
  position: relative;
}

button::after {
  content: '';
  position: absolute;
  top: -1px;
  left: -1px;
  right: -1px;
  bottom: -1px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 20px;
  pointer-events: none;
}

button:hover {
  background: linear-gradient(to bottom, #4a4a4a, #3a3a3a);
  transform: translateY(-1px);
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3),
              0 0 0 1px rgba(0, 0, 0, 0.1);
}

/* Fortune Result */
#fortuneSection, #fortuneResult {
  font-size: 1.2rem;
  color: #333;
  text-align: center;
  padding: 20px;
  max-width: 600px;
  margin: 20px auto 0;
}

#inputSection {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%; /* Ensure full width */
}

#loadingSection, #fortuneSection {
  text-align: center;
  margin-top: 20px;
  font-size: 18px;
}

@media (max-width: 480px) {
  .container {
    padding: 15px;
  }

  textarea, button {
    font-size: 14px;
  }

  #loadingSection, #fortuneSection {
    font-size: 16px;
  }
}

.hidden {
display: none;
}

.fade-out {
opacity: 0;
transform: translateY(-20px);
transition: opacity 0.5s ease, transform 0.5s ease;
}

.fade-in {
opacity: 1;
transform: translateY(0);
transition: opacity 0.5s ease, transform 0.5s ease;
}

#loadingSection, #fortuneSection {
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
text-align: center;
}
