body {
  font-family: system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  margin: 0;
  background: #f4f6f8;
  color: #1a1a1a;
}

header {
  background: #0b3d62;
  color: white;
  padding: 1rem 1.5rem;
}

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

header p {
  margin: 0.25rem 0 0;
  font-size: 0.85rem;
  opacity: 0.85;
}

main {
  display: grid;
  grid-template-columns: minmax(320px, 480px) 1fr;
  gap: 1rem;
  padding: 1rem;
  align-items: start;
}

@media (max-width: 900px) {
  main {
    grid-template-columns: 1fr;
  }
}

section.card {
  background: white;
  border-radius: 8px;
  padding: 1rem 1.25rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  margin-bottom: 1rem;
}

section.card h2 {
  margin-top: 0;
  font-size: 1rem;
  color: #0b3d62;
}

label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  margin-top: 0.6rem;
  margin-bottom: 0.2rem;
}

input, select {
  width: 100%;
  box-sizing: border-box;
  padding: 0.4rem 0.5rem;
  border: 1px solid #cbd5e1;
  border-radius: 4px;
  font-size: 0.9rem;
}

.row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}

button {
  margin-top: 1rem;
  background: #0b3d62;
  color: white;
  border: none;
  border-radius: 4px;
  padding: 0.55rem 1rem;
  font-size: 0.9rem;
  cursor: pointer;
}

button:hover {
  background: #0e4d7a;
}

button.secondary {
  background: #64748b;
}

#status {
  margin-top: 0.75rem;
  font-size: 0.85rem;
}

#status.error {
  color: #b91c1c;
}

#status.success {
  color: #15803d;
}

.log-panel {
  max-height: 85vh;
  overflow-y: auto;
}

.log-entry {
  border-radius: 6px;
  padding: 0.6rem 0.75rem;
  margin-bottom: 0.6rem;
  font-family: 'SFMono-Regular', Consolas, monospace;
  font-size: 0.75rem;
  white-space: pre-wrap;
  word-break: break-word;
}

.log-entry.request {
  background: #eef2ff;
  border-left: 4px solid #4338ca;
}

.log-entry.response {
  background: #ecfdf5;
  border-left: 4px solid #047857;
}

.log-entry .meta {
  font-weight: 700;
  margin-bottom: 0.35rem;
  font-family: system-ui, sans-serif;
  font-size: 0.75rem;
  color: #334155;
}

.result-block {
  background: #0f172a;
  color: #e2e8f0;
  border-radius: 6px;
  padding: 0.75rem;
  font-family: 'SFMono-Regular', Consolas, monospace;
  font-size: 0.75rem;
  white-space: pre-wrap;
  word-break: break-word;
  max-height: 320px;
  overflow-y: auto;
}

.result-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.result-list li {
  padding: 0.5rem 0.6rem;
  border: 1px solid #e2e8f0;
  border-radius: 4px;
  margin-bottom: 0.4rem;
  cursor: pointer;
  font-size: 0.85rem;
}

.result-list li:hover {
  background: #f1f5f9;
}
