/* Audit Completion Chart Styles */
.chart-container {
  background: var(--bg-card, #ffffff);
  border-radius: var(--border-radius, 8px);
  padding: 1.25rem 1.5rem;
  border: 1px solid var(--border-color, #e5e5e5);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  min-height: 360px;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.chart-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.25rem;
}

.chart-title {
  margin: 0;
  font-size: 1.125rem;
  font-weight: 600;
  color: #1a1a1a;
  letter-spacing: -0.3px;
}

.chart-legend {
  display: flex;
  gap: 0.75rem;
  font-size: 0.7rem;
}

.chart-legend-item {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.chart-legend-color {
  width: 10px;
  height: 10px;
  border-radius: 2px;
}

.chart-legend-color.high {
  background: #f21b23;
}

.chart-legend-color.low {
  background: #666666;
}

.chart-content {
  position: relative;
  padding-left: 2rem;
  padding-bottom: 0.75rem;
  flex: 1;
  min-height: 0;
}

.chart-y-axis {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 1.5rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  font-size: 0.7rem;
  color: #999;
  width: 1.75rem;
}

.chart-y-axis-label {
  font-size: 0.65rem;
  font-weight: 600;
  color: var(--text-muted, #757575);
  text-transform: uppercase;
  letter-spacing: 0.02em;
  margin-bottom: 0.25rem;
}

.chart-bars-container {
  display: flex;
  align-items: flex-end;
  gap: 0.625rem;
  height: 100%;
  min-height: 220px;
  max-height: 260px;
  position: relative;
}

.chart-bar-wrapper {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  height: 100%;
}

.chart-tooltip {
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  margin-bottom: 0.4rem;
  background: #1a1a1a;
  color: #ffffff;
  padding: 0.4rem 0.6rem;
  border-radius: 4px;
  font-size: 0.7rem;
  font-weight: 600;
  opacity: 0;
  transition: opacity 0.2s ease;
  white-space: nowrap;
  text-align: center;
  pointer-events: none;
  z-index: 10;
}

.chart-bar-container:hover .chart-tooltip {
  opacity: 1;
}

.chart-tooltip-month {
  font-weight: 700;
  margin-bottom: 0.2rem;
  font-size: 0.75rem;
}

.chart-tooltip-detail {
  font-size: 0.65rem;
  opacity: 0.9;
}

.chart-tooltip-rate {
  font-size: 0.65rem;
  opacity: 0.9;
  margin-top: 0.2rem;
  padding-top: 0.2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
}

.chart-bar-container {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  position: relative;
}

.chart-bar-container:hover .chart-bar {
  transform: scaleY(1.05);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.chart-bar {
  width: 100%;
  border-radius: 2px 2px 0 0;
  min-height: 20px;
  transition: all 0.3s ease;
  cursor: pointer;
  position: relative;
}

.chart-bar.high {
  background: #f21b23;
}

.chart-bar.low {
  background: #666666;
}

.chart-bar-value {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: #ffffff;
  font-size: 0.65rem;
  font-weight: 700;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.chart-month-label {
  margin-top: 0.625rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: #1a1a1a;
  text-align: center;
}

@media (max-width: 768px) {
  .chart-container {
    min-height: 300px;
    padding: 1rem;
  }
  .chart-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
    margin-bottom: 1rem;
  }
  .chart-title {
    font-size: 1rem;
  }
  .chart-legend {
    font-size: 0.65rem;
    flex-wrap: wrap;
  }
  .chart-subtitle {
    font-size: 0.75rem;
    margin-bottom: 0.5rem;
  }
  .chart-content {
    padding-left: 1.75rem;
    padding-bottom: 0.5rem;
  }
  .chart-y-axis {
    width: 1.5rem;
    font-size: 0.65rem;
  }
  .chart-bars-container {
    min-height: 180px;
    max-height: 220px;
    gap: 0.35rem;
  }
  .chart-month-label {
    font-size: 0.7rem;
  }
  .chart-rate-label {
    font-size: 0.6rem;
  }
}

@media (max-width: 480px) {
  .chart-container {
    min-height: 260px;
    padding: 0.875rem;
  }
  .chart-bars-container {
    min-height: 160px;
    max-height: 200px;
    gap: 0.25rem;
  }
  .chart-content {
    padding-left: 1.5rem;
  }
  .chart-y-axis {
    width: 1.25rem;
    font-size: 0.6rem;
  }
}

.chart-rate-label {
  margin-top: 0.2rem;
  font-size: 0.65rem;
  font-weight: 500;
  color: #666;
  text-align: center;
}

