* {
  box-sizing: border-box;
}

body {
  font-family: system-ui, -apple-system, sans-serif;
  margin: 0;
  padding: 1rem;
  background: #0f1419;
  color: #e6edf3;
  min-height: 100vh;
}

header {
  margin-bottom: 1.5rem;
}

header h1 {
  margin: 0;
  font-size: 1.5rem;
}

.subtitle {
  margin: 0.25rem 0 0;
  color: #8b949e;
  font-size: 0.9rem;
}

main {
  display: grid;
  grid-template-columns: 1fr 200px;
  gap: 1.5rem;
  max-width: 900px;
}

.input-section {
  grid-column: 1;
}

.input-section label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
}

#log-input {
  width: 100%;
  padding: 0.75rem;
  font-family: ui-monospace, monospace;
  font-size: 0.85rem;
  background: #161b22;
  border: 1px solid #30363d;
  border-radius: 6px;
  color: #e6edf3;
  resize: vertical;
}

#log-input::placeholder {
  color: #6e7681;
}

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

.actions button {
  padding: 0.5rem 1rem;
  font-size: 0.9rem;
  background: #238636;
  color: #fff;
  border: none;
  border-radius: 6px;
  cursor: pointer;
}

.actions button:hover:not(:disabled) {
  background: #2ea043;
}

.actions button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

#workflow-btn {
  background: #388bfd;
}

#workflow-btn:hover:not(:disabled) {
  background: #58a6ff;
}

.conversation-section {
  grid-column: 1;
}

.conversation-section h2 {
  margin: 0 0 0.5rem;
  font-size: 1rem;
}

.conversation-pane {
  min-height: 200px;
  max-height: 400px;
  overflow-y: auto;
  padding: 1rem;
  background: #161b22;
  border: 1px solid #30363d;
  border-radius: 6px;
}

.message {
  margin-bottom: 1rem;
}

.message strong {
  display: block;
  margin-bottom: 0.25rem;
  font-size: 0.85rem;
}

.message-user strong {
  color: #58a6ff;
}

.message-assistant strong {
  color: #3fb950;
}

.message pre {
  margin: 0;
  padding: 0.5rem;
  font-family: ui-monospace, monospace;
  font-size: 0.8rem;
  white-space: pre-wrap;
  word-break: break-word;
  background: #0d1117;
  border-radius: 4px;
}

.sidebar {
  grid-column: 2;
  grid-row: 1 / 3;
}

.sidebar h3 {
  margin: 0 0 0.5rem;
  font-size: 0.9rem;
}

.session-id {
  font-family: ui-monospace, monospace;
  font-size: 0.75rem;
  color: #8b949e;
  margin-bottom: 0.5rem;
}

#new-session-btn {
  padding: 0.4rem 0.75rem;
  font-size: 0.85rem;
  background: #21262d;
  color: #e6edf3;
  border: 1px solid #30363d;
  border-radius: 6px;
  cursor: pointer;
}

#new-session-btn:hover {
  background: #30363d;
}
