@import url("https://fonts.googleapis.com/css2?family=Archivo+Black&family=Arvo:ital,wght@0,400;0,700;1,400;1,700&family=Caveat:wght@400..700&display=swap");

body {
  font-family: "Arvo", serif;
  margin: 0;
  padding: 0;
  background-color: #f9f9f9;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
  flex: 1;
}

.header {
  text-align: center;
  margin-bottom: 20px;
  color: #333;
}

.profile-img {
  width: auto;
  height: 1em;
  border-radius: 50%;
  vertical-align: middle;
  margin-left: 5px;
}

h1 {
  margin: 0;
  font-size: 20px;
  font-weight: 600;
}

.error {
  color: red;
}

.story-input-container {
  margin-bottom: 20px;
}

#story-input {
  width: 100%;
  padding: 10px;
  border: none;
  border-radius: 5px;
  transition: border-color 0.3s ease;
  outline: none;
  background-color: #fff;
  color: #333;
}

#story-input:focus {
  border-color: purple;
}

#generated-content {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  padding: 10px;
  border: none;
  border-radius: 5px;
  background-color: #fff;
  margin-bottom: auto;
  max-height: calc(100vh - 250px);
  overflow-y: auto;
}

#generated-content p {
  margin-bottom: 30px;
  line-height: 2;
}

#generated-content img {
  width: calc(33.33% - 20px);
  height: auto;
  display: block;
  margin: 0;
  object-fit: cover;
}

.choice-buttons {
  display: flex;
  justify-content: center;
  margin-top: 20px;
}

.choice-buttons button {
  margin: 0 5px;
  padding: 8px 15px;
  border: none;
  border-radius: 5px;
  background-color: #007bff;
  color: #fff;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.choice-buttons button:hover {
  background-color: #0056b3;
}

.footer {
  text-align: center;
  padding: 10px 0;
  border-top: 1px solid #ccc;
  background-color: rgba(255, 255, 255, 0.8);
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  color: #333;
  z-index: 1000;
}

.footer a {
  color: #007bff;
  text-decoration: none;
}

.footer a:hover {
  text-decoration: underline;
}

#generated-content::-webkit-scrollbar {
  width: 8px;
}

#generated-content::-webkit-scrollbar-thumb {
  background-color: purple;
}

.spinner-wrapper {
  display: none;
  justify-content: center;
  align-items: center;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(255, 255, 255, 0.5);
  z-index: 999;
}

.spinner {
  border: 4px solid rgba(0, 0, 0, 0.1);
  border-left-color: purple;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
