/* === Reset & Base === */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg: #1a1a2e;
  --surface: #16213e;
  --text: #e0e0e0;
  --muted: #888;
  --accent: #4fc3f7;
  --accent-hover: #29b6f6;
  --success: #66bb6a;
  --danger: #ef5350;
  --radius: 8px;
  --font: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  display: flex;
  justify-content: center;
  padding: 2rem;
}

#app {
  width: 100%;
  max-width: 700px;
}

/* === Buttons === */
.btn {
  background: var(--surface);
  color: var(--text);
  border: 1px solid #333;
  border-radius: var(--radius);
  padding: 0.6rem 1.2rem;
  font-size: 0.95rem;
  cursor: pointer;
  transition: background 0.2s;
}

.btn:hover { background: #2a2a4e; }

/* === Drop Zone === */
.drop-zone {
  border: 2px dashed #444;
  border-radius: 12px;
  padding: 3rem 2rem;
  text-align: center;
  transition: border-color 0.3s;
}

.drop-zone.drag-over {
  border-color: var(--accent);
  background: rgba(79, 195, 247, 0.05);
}

.drop-zone h2 { font-size: 1.4rem; margin-bottom: 0.5rem; }
.drop-zone p { color: var(--muted); margin-bottom: 1rem; }

/* === Progress === */
.progress {
  background: var(--surface);
  border-radius: 12px;
  padding: 1.5rem;
  margin-top: 1rem;
}

.progress-header {
  display: flex;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.progress-header h3 { font-size: 1.1rem; }
#timer { color: var(--accent); font-family: monospace; }

.progress-bars { display: flex; flex-direction: column; gap: 1rem; }

.bar-row {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.bar-label { flex: 1; font-size: 0.85rem; }
.progress-bars progress { flex: 2; height: 6px; }
.speed { width: 60px; text-align: right; font-family: monospace; font-size: 0.8rem; color: var(--muted); }

/* === Results === */
.results-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
}

.results-actions { display: flex; gap: 0.5rem; }

/* === Timeline === */
.timeline {
  display: flex;
  gap: 0.4rem;
  margin-bottom: 1.5rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
}

.timeline-lane {
  flex: 1;
  border-radius: var(--radius);
  padding: 0.6rem 1rem;
  cursor: pointer;
  transition: transform 0.1s;
  font-size: 0.8rem;
  font-weight: 600;
  min-width: 80px;
  text-align: center;
}

.timeline-lane:hover { transform: scale(1.02); }

/* === Transcript === */
.transcript {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.transcript-line {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 0.8rem 1rem;
  cursor: pointer;
  display: flex;
  gap: 0.8rem;
  transition: background 0.2s;
}

.transcript-line:hover { background: #2a2a4e; }

.transcript-line.playing { background: #1e3a5f; }

.speaker-chip {
  padding: 0.3rem 0.6rem;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  white-space: nowrap;
}

.transcript-text { flex: 1; font-size: 0.9rem; line-height: 1.5; }
.transcript-text[contenteditable] { outline: none; }
.transcript-text[contenteditable]:focus { border-bottom: 2px solid var(--accent); }

/* === Modal === */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
}

.modal-content {
  background: var(--surface);
  border-radius: 12px;
  padding: 2rem;
  min-width: 300px;
}

.modal-content h3 { margin-bottom: 1rem; }

.export-options {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

/* === Utility === */
.hidden { display: none !important; }

/* === Responsive === */
@media (max-width: 500px) {
  body { padding: 1rem; }
  .drop-zone { padding: 2rem 1rem; }
}
