/**
 * Stacked Bar Chart Styles
 * Reusable styles for prompt structure visualizations
 */

/* Main wrapper */
.stacked-bar-wrapper {
  margin: 30px 0;
}

/* Single chart container */
.stacked-bar-container {
  flex: 0;
}

/* The actual chart */
.stacked-bar-chart {
  border: 2px solid #ddd;
  border-radius: 8px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

/* Individual bar items */
.stacked-bar-item {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 5px;
}

/* Bar labels */
.stacked-bar-label {
  font-weight: 600;
  font-size: 14px;
}

/* Comparison view */
.stacked-bar-comparison {
  display: flex;
  gap: 40px;
  align-items: center;
  justify-content: flex-start;
  flex-wrap: wrap;
  margin: 30px 0;
}

.stacked-bar-comparison-item {
  flex: 0;
}

/* Arrow between charts */
.stacked-bar-arrow {
  font-size: 24px;
  color: #999;
}

/* Chart titles */
.stacked-bar-title {
  text-align: center;
  margin-bottom: 20px;
  font-size: 16px;
  color: #666;
}

/* Caption */
.stacked-bar-caption {
  text-align: left;
  margin-top: 20px;
  color: #666;
  font-size: 14px;
}

/* Responsive design */
@media (max-width: 768px) {
  .stacked-bar-comparison {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .stacked-bar-arrow {
    transform: rotate(90deg);
    margin: 20px 0;
  }
}

/* Chart borders - dark mode only */
.stacked-bar-chart {
  border-color: #3d3d3d;
}

.stacked-bar-item {
  border-bottom-color: #3d3d3d !important;
}

/* Titles and captions */
.stacked-bar-title {
  color: #e0e0e0;
}

.stacked-bar-caption {
  color: #b0b0b0;
}

/* Arrow color */
.stacked-bar-arrow {
  color: #e0e0e0;
}

/* Color presets for Context Engineering theme - dark mode only */
.stacked-bar-yellow {
  background: #3d3319 !important;
}

.stacked-bar-yellow .stacked-bar-label {
  color: #fbbf24 !important;
}

.stacked-bar-green {
  background: #1a3a2e !important;
}

.stacked-bar-green .stacked-bar-label {
  color: #34d399 !important;
}

.stacked-bar-red {
  background: #3d1f1f !important;
}

.stacked-bar-red .stacked-bar-label {
  color: #f87171 !important;
}

.stacked-bar-blue {
  background: #1e3a5f !important;
}

.stacked-bar-blue .stacked-bar-label {
  color: #60a5fa !important;
}

.stacked-bar-purple {
  background: #2e1f3d !important;
}

.stacked-bar-purple .stacked-bar-label {
  color: #a78bfa !important;
}