/* === Chart Section (Modern) === */
.chart {
  padding: 2rem 1.5rem 3rem;
  margin: 0 auto;
  max-width: 1400px;
  background: transparent;
}

.chart-and-legends {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: flex-start;
  gap: 3rem;
  position: relative;
  overflow: visible;
}

.chart-wrap {
  width: 700px;
  height: 700px;
  position: relative;
  overflow: visible;
}

.chart-wrap canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100% !important;
  height: 100% !important;
}

.legend-container {
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
  flex: 1 1 240px;
  max-width: 280px;
}

.legend-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  background: white;
  padding: 0.8rem 1rem;
  border-radius: 12px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.06);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.legend-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0,0,0,0.08);
}

.legend-color-box {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid #ccc;
  flex-shrink: 0;
}

.legend-text {
  flex-grow: 1;
  font-weight: 600;
  color: #333;
  font-size: 0.95rem;
}

.legend-percentage {
  font-weight: bold;
  color: #000;
  font-size: 0.95rem;
  white-space: nowrap;
}
