:root {
  color-scheme: light dark;
  --bg: #f7f7f8;
  --surface: #ffffff;
  --border: #e2e2e6;
  --text: #1c1c1f;
  --text-muted: #6b6b73;
  --accent: #2f6fed;
  --error-bg: #fdeceb;
  --error-text: #b3261e;
  --info-text: #6b6b73;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #17171a;
    --surface: #1f1f23;
    --border: #313136;
    --text: #f0f0f2;
    --text-muted: #a2a2ab;
    --accent: #6d9bff;
    --error-bg: #3a2222;
    --error-text: #ff8a80;
    --info-text: #a2a2ab;
  }
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.page {
  max-width: 720px;
  margin: 0 auto;
  padding: 48px 24px;
}

h1 {
  font-size: 1.5rem;
  margin-bottom: 24px;
}

.search-form {
  display: flex;
  gap: 8px;
  margin-bottom: 20px;
}

.search-form input {
  flex: 1;
  padding: 10px 12px;
  font-size: 1rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text);
}

.search-form button {
  padding: 10px 20px;
  font-size: 1rem;
  border: none;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  cursor: pointer;
}

.search-form button:hover {
  opacity: 0.9;
}

.status {
  margin-bottom: 16px;
  font-size: 0.95rem;
}

.status--info {
  color: var(--info-text);
}

.status--error {
  padding: 10px 12px;
  border-radius: 8px;
  background: var(--error-bg);
  color: var(--error-text);
}

.result {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 24px;
}

.detail-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.detail-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

.detail-row:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.detail-label {
  color: var(--text-muted);
  font-size: 0.85rem;
}

.detail-value {
  font-weight: 500;
  text-align: right;
}

.description {
  margin-top: 20px;
}

.description h2 {
  font-size: 1rem;
  margin-bottom: 8px;
}

.description p {
  line-height: 1.5;
  color: var(--text);
}

.raw-json {
  margin-top: 20px;
}

.raw-json summary {
  cursor: pointer;
  color: var(--text-muted);
  font-size: 0.85rem;
}

.raw-json pre {
  margin-top: 12px;
  padding: 12px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow-x: auto;
  font-size: 0.8rem;
}
