.chart-frame {
  background: #fff;
  box-shadow: var(--shadow-lg);
  border-radius: var(--radius-md);
  overflow: hidden;
  flex: 0 0 auto;
}

.chart-canvas {
  width: 100%;
  height: 100%;
}

/* Copy-chart button — lives ON the chart itself (not the app-wide top
   toolbar) specifically so it's unambiguous that it copies the CHART
   IMAGE, not the data grid; revealed on hover so it doesn't clutter the
   canvas the rest of the time. */
.chart-hover-frame {
  position: relative;
  display: inline-block;
}
.chart-hover-frame__copy-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  background: #fff;
  border: 1px solid var(--ui-border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  font-size: var(--text-xs);
  color: var(--ui-text);
  opacity: 0;
  transform: translateY(-2px);
  transition: opacity 0.12s ease, transform 0.12s ease;
  pointer-events: none;
}
.chart-hover-frame:hover .chart-hover-frame__copy-btn,
.chart-hover-frame__copy-btn--active {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
.chart-hover-frame__copy-btn:hover { border-color: var(--color-secondary); }

.zoom-controls {
  display: flex;
  align-items: center;
  gap: var(--space-1);
}

.zoom-controls__label {
  display: inline-flex;
  align-items: center;
  gap: 1px;
  font-size: var(--text-xs);
  color: var(--ui-text-muted);
  min-width: 38px;
  justify-content: center;
}

.zoom-controls__input {
  width: 28px;
  border: none;
  background: transparent;
  font: inherit;
  color: inherit;
  text-align: right;
  padding: 2px 0;
  border-radius: var(--radius-sm);
}
.zoom-controls__input:hover,
.zoom-controls__input:focus {
  background: var(--ui-bg-subtle);
  outline: none;
}

.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-4);
  text-align: center;
  color: var(--ui-text-secondary);
  max-width: 360px;
  margin: 0 auto;
}

.empty-state__icon {
  width: 56px; height: 56px;
  border-radius: var(--radius-lg);
  background: var(--color-primary-light);
  color: var(--color-primary);
  display: flex; align-items: center; justify-content: center;
}

.empty-state__title { font-size: var(--text-xl); color: var(--ui-text); }
.empty-state__desc { font-size: var(--text-sm); color: var(--ui-text-muted); }

.empty-state__actions {
  display: flex;
  gap: var(--space-2);
}

.error-banner {
  display: flex;
  align-items: flex-start;
  gap: var(--space-2);
  background: #FFF4F4;
  border: 1px solid #FFD1D1;
  color: #A61B1B;
  border-radius: var(--radius-md);
  padding: var(--space-3);
  font-size: var(--text-sm);
  margin-bottom: var(--space-3);
}
