* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  background: #f8f9fa;
  color: #1a1a1a;
  padding: 2rem 1rem;
  overflow-x: hidden;
}
h1 {
  text-align: center;
  font-size: 1.6rem;
  font-weight: 600;
  margin-bottom: 0.4rem;
}
.subtitle {
  text-align: center;
  color: #666;
  font-size: 0.95rem;
  margin-bottom: 2rem;
}
.charts-container {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  justify-content: center;
  max-width: 1200px;
  margin: 0 auto;
}
.chart-panel {
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.08);
  padding: 1.5rem;
  flex: 1 1 480px;
  max-width: 560px;
  min-width: 340px;
}
.chart-panel h2 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.3rem;
}
.chart-panel .chart-desc {
  font-size: 0.82rem;
  color: #888;
  margin-bottom: 1rem;
}
canvas {
  width: 100%;
  height: 320px;
  display: block;
}
.controls {
  text-align: center;
  margin: 2rem auto 1rem;
  max-width: 600px;
}
.controls label {
  font-size: 0.9rem;
  font-weight: 500;
  margin-right: 0.5rem;
}
.controls input[type="range"] {
  width: 60%;
  vertical-align: middle;
}
.controls .b-label {
  display: inline-block;
  min-width: 7rem;
  font-weight: 700;
  font-size: 1rem;
  color: #1F4E9E;
  text-align: left;
}
.legend {
  display: flex;
  gap: 1.5rem;
  justify-content: center;
  margin-top: 0.8rem;
  font-size: 0.85rem;
}
.legend-item {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}
.legend-swatch {
  width: 14px;
  height: 14px;
  border-radius: 3px;
}
