html, body {
  overflow-x: hidden;
}

body {
  margin: 0;
  padding: 0;
  background: #0e0f50; /* your custom dark blue */
  font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', sans-serif;
  color: #ffffff;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.container {
  background: #1a1b1f;
  padding: 40px 30px;
  border-radius: 16px;
  max-width: 600px;
  width: 100%;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
  text-align: center;
  box-sizing: border-box;
}


.container h1 {
  font-size: 2rem;
  margin-bottom: 10px;
}

.container p {
  font-size: 0.95rem;
  color: #b0b3b8;
  margin-bottom: 20px;
}

textarea {
  width: 100%;
  height: 150px;
  font-size: 16px;
  padding: 12px;
  margin: 20px 0;
  border: 1px solid #444;
  border-radius: 8px;
  resize: vertical;
  background-color: #2f2f35;
  color: #fff;
  box-sizing: border-box;
  font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', sans-serif;
}

textarea::placeholder {
  color: #aaa;
  font-style: normal;
  font-family: 'Inter', system-ui, sans-serif;
}

.controls {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 12px;
  margin-bottom: 30px;
  width: 100%;
  box-sizing: border-box;
}


.controls select,
.controls button {
  padding: 10px 16px;
  font-size: 15px;
  border-radius: 6px;
  border: none;
  box-sizing: border-box;
}

select {
  background: #2f2f35;
  color: white;
  width: 150px;
  margin: 0 auto;         /* ⬅ Center it */
  display: block;         /* ⬅ Required for margin auto to work */
}


button {
  cursor: pointer;
  transition: background-color 0.2s ease;
}

button:hover {
  opacity: 0.9;
}

button:active {
  transform: scale(0.98);
}

button[onclick*="fixTone"] {
  background-color: #2d72fc;
  color: white;
}

#copyButton {
  background-color: #2d72fc;
  color: white;
  border: none;
  padding: 10px 16px;
  font-size: 15px;
  border-radius: 6px;
  margin-top: 20px;
  cursor: pointer;
  transition: background-color 0.2s ease;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

#copyButton:hover {
  background-color: #2565e0;
}

#copyButton:active {
  transform: scale(0.98);
}

.outputBox {
  background-color: #2f2f35;
  padding: 16px;
  border-radius: 8px;
  text-align: left;
  font-size: 15px;
  white-space: pre-wrap;
  color: #f1f1f1;
  margin-top: 20px;
  box-sizing: border-box;
}

.tone-description {
  font-size: 0.9rem;
  color: #ccc;
  margin-top: 10px;
  margin-bottom: 0;
  text-align: center;
  line-height: 1.3;
  max-width: 100%;
  word-wrap: break-word;
  padding: 0 6px;
}

.spinner {
  border: 6px solid #f3f3f3;
  border-top: 6px solid #3498db;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  animation: spin 0.8s linear infinite;
  margin: 20px auto;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

@media (max-width: 600px) {
  .container {
    margin: 20px 10px;
    padding: 20px;
    border-radius: 14px;
  }

  textarea {
    height: 120px;
    font-size: 15px;
  }

  .controls {
    flex-direction: column;
    gap: 12px;
  }

  select,
  button {
    width: 100%;
    font-size: 15px;
  }

  .outputBox {
    font-size: 15px;
    padding: 16px;
  }

  #copyButton {
    width: 100%;
    margin-top: 12px;
  }

  .tone-description {
    font-size: 13px;
    text-align: center;
    padding: 4px 6px;
  }
}
footer {
  position: relative;
  width: 100%;
  text-align: center;
  margin-top: 60px;
}
