:root {
  --bg: #f7f6f3;
  --card: #ffffff;
  --text: #111111;
  --muted: #787774;
  --border: #eaeaea;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "SF Pro Display", "Segoe UI", "Helvetica Neue", sans-serif;
  background: radial-gradient(circle at 20% 10%, rgba(0, 0, 0, 0.03), transparent 40%), var(--bg);
  color: var(--text);
}

.page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 32px 20px;
}

.card {
  width: min(760px, 100%);
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 32px;
}

.loader-overlay {
  margin-top: 12px;
  display: block;
}

.loader-overlay[hidden] {
  display: none !important;
}

.loader-box {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #ffffff;
  padding: 18px;
}

.loader-spinner {
  width: 24px;
  height: 24px;
  border: 3px solid #dddddd;
  border-top-color: #111111;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

.loader-text {
  margin: 12px 0 10px;
  color: #111111;
  font-weight: 600;
}

.loader-track {
  width: 100%;
  height: 7px;
  border-radius: 9999px;
  background: #efefef;
  overflow: hidden;
}

.loader-bar {
  width: 0%;
  height: 100%;
  border-radius: 9999px;
  background: #111111;
  transition: width 0.6s ease;
}

.loader-elapsed {
  margin: 8px 0 0;
  font-size: 12px;
  color: var(--muted);
}

.badge {
  display: inline-block;
  margin: 0 0 16px;
  padding: 6px 10px;
  border-radius: 9999px;
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  background: #edf3ec;
  color: #346538;
}

h1 {
  margin: 0;
  font-family: "Newsreader", "Times New Roman", serif;
  letter-spacing: -0.02em;
  line-height: 1.1;
  font-size: clamp(28px, 4vw, 40px);
}

.subtext {
  margin: 14px 0 24px;
  color: var(--muted);
  line-height: 1.6;
}

.upload-form {
  display: grid;
  gap: 12px;
}

.drop-zone {
  border: 1px dashed #d7d7d7;
  border-radius: 10px;
  background: #fbfbfa;
  padding: 22px;
  cursor: pointer;
  display: grid;
  gap: 6px;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.drop-zone:hover,
.drop-zone.drag-over {
  border-color: #8a8a8a;
  background: #f6f6f4;
}

.drop-title {
  font-weight: 600;
}

.drop-subtitle {
  font-size: 13px;
  color: var(--muted);
}

input[type="file"] {
  display: none;
}

.file-meta-row {
  display: grid;
  gap: 10px;
}

.file-meta {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
}

.audio-preview {
  width: 100%;
}

button {
  width: fit-content;
  border: none;
  border-radius: 6px;
  background: #111111;
  color: #ffffff;
  padding: 10px 16px;
  font-size: 14px;
  cursor: pointer;
  transition: transform 0.2s ease, background-color 0.2s ease;
}

button:hover {
  background: #333333;
}

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

.status {
  min-height: 20px;
  margin: 16px 0 10px;
  color: var(--muted);
}

.status.busy::before {
  content: "";
  display: inline-block;
  width: 10px;
  height: 10px;
  margin-right: 8px;
  border: 2px solid #cfcfcf;
  border-top-color: #111111;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  vertical-align: -1px;
}

.result-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 6px 0 8px;
}

.result-label {
  color: var(--muted);
  font-size: 13px;
}

.result-actions {
  display: flex;
  gap: 8px;
}

.ghost-btn {
  border: 1px solid var(--border);
  background: #fff;
  color: #2f2f2f;
  padding: 8px 12px;
}

.ghost-btn:hover {
  background: #f9f9f8;
}

.ghost-btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.result {
  min-height: 140px;
  margin: 0;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #f9f9f8;
  padding: 14px;
  white-space: pre-wrap;
  line-height: 1.5;
  font-family: "JetBrains Mono", "SF Mono", monospace;
}

.minutes-wrap {
  margin-top: 14px;
}

.minutes {
  min-height: 110px;
  margin: 6px 0 0;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #ffffff;
  padding: 14px;
  white-space: pre-wrap;
  line-height: 1.6;
  font-family: "SF Pro Display", "Segoe UI", "Helvetica Neue", sans-serif;
}

.reveal {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

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

