* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: #f5f5f5;
  color: #1a1a1a;
  min-height: 100vh;
  display: flex;
  justify-content: center;
  padding: 2rem 1rem;
}

main {
  width: 100%;
  max-width: 1400px;
}

h1 {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
}

.controls {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}

button {
  padding: 0.6rem 1.2rem;
  border: none;
  border-radius: 6px;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s;
}

#record-btn {
  background: #2563eb;
  color: #fff;
}

#record-btn:hover {
  background: #1d4ed8;
}

#record-btn.recording {
  background: #dc2626;
}

#record-btn.recording:hover {
  background: #b91c1c;
}

#save-btn {
  background: #e5e7eb;
  color: #374151;
}

#save-btn:hover:not(:disabled) {
  background: #d1d5db;
}

#save-btn:disabled {
  opacity: 0.4;
  cursor: default;
}

#refresh-btn {
  background: #e5e7eb;
  color: #374151;
}

#refresh-btn:hover:not(:disabled) {
  background: #d1d5db;
}

#refresh-btn:disabled {
  opacity: 0.4;
  cursor: default;
}

#lang-select {
  padding: 0.6rem 0.8rem;
  border: 1px solid #e5e7eb;
  border-radius: 6px;
  font-size: 0.9rem;
  background: #fff;
  color: #374151;
  cursor: pointer;
}

.status {
  font-size: 0.8rem;
  color: #6b7280;
  min-height: 1.2rem;
  margin-bottom: 0.75rem;
}

.panels {
  display: flex;
  gap: 1.25rem;
  align-items: flex-start;
}

.transcript {
  flex: 1;
  min-width: 0;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 1.25rem;
  min-height: 300px;
  max-height: 70vh;
  overflow-y: auto;
  white-space: pre-wrap;
  font-size: 0.95rem;
  line-height: 1.6;
}

.summary-panel {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.summary-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: 0.85rem;
  font-weight: 600;
  color: #374151;
}

.last-updated {
  font-size: 0.75rem;
  font-weight: 400;
  color: #9ca3af;
}

.summary {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 1.25rem;
  min-height: 300px;
  max-height: 70vh;
  overflow-y: auto;
  font-size: 0.95rem;
  line-height: 1.6;
  color: #374151;
}

.exec-section {
  margin-top: 1.25rem;
}

.exec-header {
  margin-bottom: 0.75rem;
}

#exec-btn {
  background: #4f46e5;
  color: #fff;
}

#exec-btn:hover:not(:disabled) {
  background: #4338ca;
}

#exec-btn:disabled {
  opacity: 0.4;
  cursor: default;
}

.exec-summary {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 1.25rem;
  font-size: 0.95rem;
  line-height: 1.6;
  color: #374151;
}

.summary h1, .summary h2, .summary h3,
.exec-summary h1, .exec-summary h2, .exec-summary h3 {
  font-weight: 600;
  margin: 0.75rem 0 0.35rem;
  color: #111827;
}

.summary h1, .exec-summary h1 { font-size: 1.1rem; }
.summary h2, .exec-summary h2 { font-size: 1rem; }
.summary h3, .exec-summary h3 { font-size: 0.95rem; }

.summary p, .exec-summary p { margin: 0.4rem 0; }

.summary ul, .summary ol,
.exec-summary ul, .exec-summary ol {
  padding-left: 1.25rem;
  margin: 0.35rem 0;
}

.summary li, .exec-summary li { margin: 0.2rem 0; }

.summary strong, .exec-summary strong { font-weight: 600; color: #111827; }

.summary code, .exec-summary code {
  background: #f3f4f6;
  padding: 0.1em 0.35em;
  border-radius: 3px;
  font-size: 0.88em;
}
