/* General styling */
body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background-color: #f0f4f8;
  margin: 0;
  padding: 20px;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  min-height: 100vh;
}

.container {
  max-width: 650px;
  width: 100%;
  background: #ffffff;
  padding: 30px 25px;
  border-radius: 20px;
  box-shadow: 0 8px 20px rgba(0,0,0,0.1);
  text-align: center;
}

h1 {
  margin: 0 0 10px 0;
  font-size: 2.2em;
  color: #1a1a1a;
}

.subtitle {
  color: #4a4a4a;
  margin-bottom: 25px;
  font-size: 1.1em;
}

/* Upload area */
.upload-box {
  margin: 20px 0;
}

.upload-label {
  display: inline-block;
  background: #0077cc;
  color: #ffffff;
  padding: 12px 20px;
  border-radius: 10px;
  cursor: pointer;
  font-size: 1em;
  font-weight: 600;
  /* transition: background 0.25s, transform 0.2s; */
}

.upload-label:hover {
  background: #005fa3;
  /* transform: translateY(-2px); */
}

#imageInput {
  display: none;
}

.preview {
  margin: 20px 0;
}

.preview img {
  max-width: 100%;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

/* Buttons */
button {
  background: #0077cc;
  color: white;
  border: none;
  padding: 12px 22px;
  margin: 8px 4px;
  border-radius: 10px;
  cursor: pointer;
  font-size: 1em;
  font-weight: 600;
  /* transition: background 0.25s, transform 0.2s, box-shadow 0.2s; */
}

button:hover:not(:disabled) {
  background: #005fa3;
  /* transform: translateY(-2px); */
  box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

button:disabled {
  background: #cccccc;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* Output area */
.output {
  margin-top: 25px;
  text-align: left;
}

.hidden {
  display: none;
}

textarea {
  width: 100%;
  height: 180px;
  resize: none;
  margin-top: 12px;
  padding: 14px;
  font-size: 1em;
  border-radius: 12px;
  border: 1px solid #bbb;
  background: #fafafa;
  color: #222;
  line-height: 1.5em;
  box-shadow: inset 0 2px 4px rgba(0,0,0,0.05);
}

/* Control buttons */
.controls {
  text-align: center;
  margin-top: 18px;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
}

/* Voice selector */
.voice-selector {
  margin-top: 15px;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 12px;
  flex-wrap: wrap;
}

.voice-selector label {
  font-weight: 600;
  font-size: 0.95em;
  color: #333;
}

.voice-selector select {
  padding: 7px 12px;
  border-radius: 8px;
  border: 1px solid #aaa;
  font-size: 0.95em;
  background: #fff;
  color: #222;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
  transition: border 0.2s, box-shadow 0.2s;
}

.voice-selector select:focus {
  border-color: #0077cc;
  box-shadow: 0 2px 8px rgba(0,119,204,0.25);
  outline: none;
}

/* Responsive adjustments */
@media (max-width: 480px) {
  .container {
    padding: 20px 15px;
  }

  .upload-label, button {
    width: 100%;
    margin: 6px 0;
  }

  .voice-selector {
    flex-direction: column;
    align-items: flex-start;
  }
}
