body { font-family: Arial, sans-serif; margin: 0; padding: 0; background: #fafafa; color: #222; }
.container { max-width: 1100px; margin: 24px auto; padding: 0 16px; }
h1 { margin-bottom: 16px; }
.query-box { display: flex; gap: 8px; margin-bottom: 16px; }
.query-box input { flex: 1; padding: 10px; font-size: 16px; }
.query-box button { padding: 10px 16px; font-size: 16px; cursor: pointer; }
.schema-toggle { margin-bottom: 16px; padding: 10px; background: #fff; border: 1px solid #e5e5e5; border-radius: 6px; }
.schema-toggle label { display: flex; align-items: center; gap: 8px; cursor: pointer; font-size: 14px; }
.schema-toggle input[type="checkbox"] { cursor: pointer; width: 18px; height: 18px; }
.section { background: #fff; border: 1px solid #e5e5e5; padding: 12px; margin-bottom: 16px; border-radius: 6px; }
pre { background: #f5f5f5; padding: 10px; border-radius: 6px; overflow: auto; white-space: pre-wrap; }
table { width: 100%; border-collapse: collapse; }
th, td { border: 1px solid #ddd; padding: 8px; }
th { background: #f0f0f0; }
.attempt { font-family: monospace; white-space: pre-wrap; background: #f8f8f8; border: 1px dashed #ccc; border-radius: 4px; padding: 8px; margin: 8px 0; }

.summary { background: #f7f8fb; border: 1px solid #e6e9f2; padding: 10px; border-radius: 6px; margin: 8px 0; color: #1f2937; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 8px; margin: 8px 0; }
.stat-card { background: #fbfbfb; border: 1px solid #e5e5e5; padding: 10px; border-radius: 6px; }
.charts { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 12px; }
.chart-card { background: #fff; border: 1px solid #eaeaea; border-radius: 8px; padding: 8px; box-shadow: 0 1px 2px rgba(0,0,0,0.04); }
.chart-actions { display: flex; justify-content: flex-end; margin: 8px 0; }
.chart-actions button { padding: 8px 12px; font-size: 14px; cursor: pointer; }

/* loader */
#loader { display: none; align-items: center; gap: 8px; }
.spinner {
  width: 16px; height: 16px; border: 2px solid #ccc; border-top-color: #333; border-radius: 50%;
  display: inline-block; animation: spin 0.9s linear infinite;
}
@keyframes spin { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }

/* inline section loaders */
.inline-loader { display: none; align-items: center; gap: 8px; margin-bottom: 8px; }
.inline-loader .dots { display: inline-flex; gap: 4px; }
.inline-loader .dots span { width: 8px; height: 8px; background: #555; border-radius: 50%; display: inline-block; animation: bounce 1.2s infinite ease-in-out; }
.inline-loader .dots span:nth-child(2) { animation-delay: 0.15s; }
.inline-loader .dots span:nth-child(3) { animation-delay: 0.3s; }
.inline-loader .msg { color: #555; font-size: 14px; }

@keyframes bounce {
  0%, 80%, 100% { transform: scale(0); opacity: 0.5; }
  40% { transform: scale(1); opacity: 1; }
}

