:root {
  color-scheme: light;
  --ink: #18201e;
  --muted: #66716e;
  --paper: #f4f1ea;
  --card: #fffdf8;
  --line: #d9d8cf;
  --teal: #0f766e;
  --teal-dark: #0a514c;
  --teal-soft: #d9ece7;
  --amber: #e8a44c;
  --danger: #a23b35;
  --shadow: 0 28px 70px rgba(30, 51, 47, 0.11);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background:
    radial-gradient(circle at 15% 0%, rgba(232, 164, 76, 0.15), transparent 28rem),
    linear-gradient(180deg, #f8f5ee 0%, var(--paper) 100%);
}

button, select, textarea { font: inherit; }
button { color: inherit; }

.site-header {
  width: min(1180px, calc(100% - 40px));
  height: 78px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  border-bottom: 1px solid rgba(24, 32, 30, 0.12);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-size: 0.88rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-decoration: none;
}

.brand-mark {
  width: 31px;
  height: 31px;
  display: grid;
  place-items: center;
  color: white;
  background: var(--teal);
  border-radius: 9px;
  font-family: Georgia, serif;
  font-size: 1.18rem;
  letter-spacing: 0;
}

.tool-name { color: var(--muted); font-weight: 650; }

.free-pill {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--teal-dark);
  font-size: 0.8rem;
  font-weight: 700;
}

.free-pill span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #2ca66f;
  box-shadow: 0 0 0 5px rgba(44, 166, 111, 0.12);
}

main { width: min(980px, calc(100% - 40px)); margin: 0 auto; }

.hero { padding: 78px 0 44px; text-align: center; }
.eyebrow {
  margin: 0 0 14px;
  color: var(--teal);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.17em;
  text-transform: uppercase;
}

h1, h2, h3, p { margin-top: 0; }
h1, h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 500;
  letter-spacing: -0.035em;
}

h1 { margin-bottom: 18px; font-size: clamp(2.8rem, 7vw, 5.8rem); line-height: 0.98; }
.hero-copy { max-width: 640px; margin: 0 auto; color: var(--muted); font-size: 1.08rem; line-height: 1.75; }

.workspace {
  position: relative;
  min-height: 430px;
  padding: clamp(24px, 5vw, 48px);
  overflow: hidden;
  background: rgba(255, 253, 248, 0.95);
  border: 1px solid rgba(24, 32, 30, 0.12);
  border-radius: 28px;
  box-shadow: var(--shadow);
}

.workspace::before {
  position: absolute;
  width: 190px;
  height: 190px;
  right: -100px;
  top: -100px;
  content: "";
  border: 40px solid var(--teal-soft);
  border-radius: 50%;
  pointer-events: none;
}

.notice {
  position: relative;
  z-index: 1;
  margin-bottom: 20px;
  padding: 13px 16px;
  color: #63352f;
  background: #f7e7df;
  border: 1px solid #e8c3b7;
  border-radius: 12px;
}

.dropzone {
  position: relative;
  z-index: 1;
  min-height: 280px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 34px;
  text-align: center;
  background: #faf9f4;
  border: 1.5px dashed #a9b8b3;
  border-radius: 20px;
  transition: 160ms ease;
  cursor: pointer;
}

.dropzone:hover, .dropzone:focus-visible, .dropzone.is-dragging {
  border-color: var(--teal);
  background: #f2f8f5;
  outline: none;
  transform: translateY(-2px);
}

.dropzone h2 { margin: 20px 0 8px; font-size: 2rem; }
.dropzone p { margin-bottom: 18px; color: var(--muted); }
.dropzone .file-help { margin: 22px 0 0; font-size: 0.78rem; }

.wave-icon { height: 43px; display: flex; align-items: center; gap: 5px; }
.wave-icon span { width: 5px; height: 18px; background: var(--teal); border-radius: 4px; }
.wave-icon span:nth-child(2), .wave-icon span:nth-child(4) { height: 32px; }
.wave-icon span:nth-child(3) { height: 43px; background: var(--amber); }

.button {
  min-height: 46px;
  padding: 0 20px;
  border: 1px solid transparent;
  border-radius: 12px;
  font-weight: 750;
  cursor: pointer;
  transition: 140ms ease;
}
.button:disabled { opacity: 0.45; cursor: not-allowed; }
.button:not(:disabled):hover { transform: translateY(-1px); }
.button-primary { color: white; background: var(--teal); box-shadow: 0 8px 22px rgba(15, 118, 110, 0.2); }
.button-primary:not(:disabled):hover { background: var(--teal-dark); }
.button-secondary { background: transparent; border-color: #bcc5c1; }
.button-secondary:not(:disabled):hover { border-color: var(--teal); color: var(--teal-dark); }

#transcribeButton { width: 100%; margin-top: 24px; min-height: 54px; }

.file-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px;
  background: #f2f8f5;
  border: 1px solid #c8dfd8;
  border-radius: 16px;
}
.file-badge { width: 44px; height: 44px; display: grid; place-items: center; color: white; background: var(--teal); border-radius: 12px; font-size: 1.2rem; }
.file-meta { min-width: 0; flex: 1; display: flex; flex-direction: column; gap: 4px; }
.file-meta strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-meta span { color: var(--muted); font-size: 0.82rem; }
.icon-button { width: 38px; height: 38px; border: 0; background: transparent; border-radius: 50%; font-size: 1.5rem; cursor: pointer; }
.icon-button:hover { background: rgba(15, 118, 110, 0.1); }

.controls { margin-top: 22px; display: grid; grid-template-columns: minmax(220px, 1fr) auto; align-items: end; gap: 20px; }
.controls label { display: grid; gap: 8px; color: var(--muted); font-size: 0.79rem; font-weight: 700; }
select { min-height: 46px; padding: 0 42px 0 14px; color: var(--ink); background: var(--card); border: 1px solid #c7ccc9; border-radius: 11px; }
.turnstile-slot { min-height: 0; }

.progress-view { min-height: 340px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
.progress-view h2 { margin-bottom: 10px; font-size: 2.5rem; }
.progress-view > p:not(.eyebrow) { color: var(--muted); }
.progress-orbit { width: 74px; height: 74px; margin-bottom: 30px; border: 1px solid #bdd4ce; border-radius: 50%; animation: spin 2s linear infinite; }
.progress-orbit span { display: block; width: 16px; height: 16px; margin: -2px auto 0; background: var(--amber); border-radius: 50%; }
@keyframes spin { to { transform: rotate(360deg); } }
.progress-track { width: min(560px, 100%); height: 8px; margin-top: 24px; overflow: hidden; background: #e3e5df; border-radius: 9px; }
.progress-track span { display: block; width: 0; height: 100%; background: linear-gradient(90deg, var(--teal), #45a48f); transition: width 400ms ease; }
.progress-row { width: min(560px, 100%); margin-top: 10px; display: flex; justify-content: space-between; color: var(--muted); font-size: 0.8rem; }
.text-button { padding: 0; color: var(--danger); background: none; border: 0; cursor: pointer; }

.result-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; }
.result-header h2 { margin-bottom: 18px; font-size: 2.4rem; }
#transcriptText { width: 100%; min-height: 310px; resize: vertical; padding: 20px; color: var(--ink); background: #faf9f4; border: 1px solid #ccd1ce; border-radius: 16px; line-height: 1.65; }
#transcriptText:focus { outline: 2px solid rgba(15, 118, 110, 0.25); border-color: var(--teal); }
.result-actions { margin-top: 16px; display: flex; flex-wrap: wrap; gap: 10px; }
.retention-note { margin: 20px 0 0; color: var(--muted); font-size: 0.78rem; }

.trust-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; margin: 76px 0; background: var(--line); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.trust-grid article { padding: 32px; background: var(--paper); }
.trust-number { color: var(--teal); font-family: Georgia, serif; font-size: 0.8rem; }
.trust-grid h3 { margin: 20px 0 10px; font-size: 1rem; }
.trust-grid p { margin: 0; color: var(--muted); font-size: 0.88rem; line-height: 1.65; }

footer { width: min(1180px, calc(100% - 40px)); margin: 0 auto; padding: 28px 0 42px; display: flex; justify-content: space-between; gap: 20px; color: var(--muted); border-top: 1px solid rgba(24, 32, 30, 0.12); font-size: 0.76rem; }
.hidden { display: none !important; }

@media (max-width: 720px) {
  .site-header { grid-template-columns: 1fr auto; }
  .tool-name { display: none; }
  .hero { padding-top: 56px; }
  .workspace { padding: 20px; border-radius: 20px; }
  .dropzone { min-height: 250px; padding: 24px 16px; }
  .controls { grid-template-columns: 1fr; }
  .result-header { flex-direction: column; }
  .trust-grid { grid-template-columns: 1fr; }
  footer { flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}

