/* 实时语音翻译 - 样式 */
:root {
  --bg: #0f0f12;
  --surface: #1a1a20;
  --border: #2a2a32;
  --text: #e8e8ed;
  --text-muted: #8888a0;
  --accent: #5b8def;
  --accent-hover: #7aa3f5;
  --stop: #e85b5b;
  --font-sans: "SF Pro Text", "Segoe UI", system-ui, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
}

.app {
  max-width: 720px;
  margin: 0 auto;
  padding: 2rem 1.5rem;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

header {
  text-align: center;
  margin-bottom: 2rem;
}

header h1 {
  font-size: 1.75rem;
  font-weight: 600;
  margin: 0 0 0.25rem 0;
}

.subtitle {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin: 0;
}

.controls {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  margin-bottom: 1.5rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.25rem;
  font-size: 1rem;
  font-weight: 500;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s;
}

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

.btn:not(:disabled):hover {
  transform: translateY(-1px);
}

.btn-primary {
  background: var(--accent);
  color: #fff;
}

.btn-primary:not(:disabled):hover {
  background: var(--accent-hover);
}

.btn-secondary {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-secondary:not(:disabled):hover {
  background: var(--border);
}

.btn-icon {
  font-size: 1.1rem;
}

.status {
  text-align: center;
  padding: 0.6rem;
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
  min-height: 2rem;
}

.status.listening {
  color: var(--accent);
  font-weight: 500;
}

.status.error {
  color: var(--stop);
}

.panels {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  flex: 1;
}

@media (max-width: 600px) {
  .panels {
    grid-template-columns: 1fr;
  }
}

.panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1rem 1.25rem;
}

.panel h2 {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  margin: 0 0 0.75rem 0;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.text-box {
  min-height: 120px;
  font-size: 1rem;
  line-height: 1.6;
  white-space: pre-wrap;
  word-break: break-word;
}

.text-box:empty::before {
  content: "—";
  color: var(--text-muted);
}

footer {
  margin-top: 2rem;
  text-align: center;
  font-size: 0.8rem;
  color: var(--text-muted);
}

footer p {
  margin: 0;
}
