/* quantity-visualizer.css — Bühne, Token, Gruppen-Boxen, Container, Schalter */

.visualization-container {
  margin-top: 12px;
  padding: 12px 14px 16px;
  background: #fff;
  border: 1px solid #e3e7ee;
  border-radius: 12px;
}

.qv-stage {
  position: relative;
  width: 100%;
  min-height: 200px;
  max-height: 60vh;        /* große Mengen scrollen statt die Seite zu sprengen */
  overflow: auto;
}

.qv-token {
  position: absolute;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  /* Bewegung/Dauer werden in JS pro Token gesetzt (Geschwindigkeit + Staffelung) */
  transition: left .95s cubic-bezier(.2, .8, .25, 1), top .95s cubic-bezier(.2, .8, .25, 1), transform .95s cubic-bezier(.2, .8, .25, 1), opacity .6s ease, background-color .3s;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}
.qv-token.qv-red    { background-color: #e8533f; }
.qv-token.qv-blue   { background-color: #3f73e8; }
.qv-token.qv-green  { background-color: #2fa35e; }
.qv-token.qv-orange { background-color: #f0962a; }
.qv-token.qv-violet { background-color: #8b5cf6; }
.qv-token.qv-symbol { background-color: transparent !important; width: 30px; height: 30px; }
/* Weggenommene Token: verblassen sanft (Opacity wird inline animiert), bleiben blass sichtbar */
.qv-token.qv-ghost {
  filter: grayscale(35%);
}

.qv-box {
  position: absolute;
  border: 2px dashed #aab2bf;
  border-radius: 9px;
  transition: opacity .3s ease;
  pointer-events: none;
}
.qv-box-label {
  position: absolute;
  font-size: 12px;
  color: #6b7585;
  white-space: nowrap;
}

.qv-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin: 0 0 10px;
}

.qv-show-all-btn {
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  border: 1px solid #c4ccd6;
  background: #f4f6fa;
  border-radius: 8px;
  padding: 6px 12px;
  cursor: pointer;
}
.qv-show-all-btn:hover { background: #e9edf4; }
.qv-show-all-btn:disabled { opacity: .6; cursor: default; }

.qv-toggle {
  display: inline-flex;
  gap: 6px;
}
.qv-toggle button {
  font: inherit;
  font-size: 13px;
  border: 1px solid #c4ccd6;
  background: #fff;
  border-radius: 7px;
  padding: 5px 12px;
  cursor: pointer;
}
.qv-toggle button.active {
  background: #1f2733;
  color: #fff;
  border-color: #1f2733;
}

/* Symbol-Modus: größere Token brauchen etwas mehr Luft */
.qv-stage.qv-symbols .qv-token { width: 30px; height: 30px; }

.qv-caption {
  font-size: 14px;
  color: #1f2733;
  margin: 0 0 8px;
  min-height: 18px;
  font-weight: 500;
}

.qv-stepnav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin-top: 10px;
}
.qv-nav-btn {
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  border: 1px solid #c4ccd6;
  background: #fff;
  border-radius: 8px;
  padding: 6px 14px;
  cursor: pointer;
}
.qv-nav-btn:hover:not(:disabled) { background: #eef2f7; }
.qv-nav-btn:disabled { opacity: .4; cursor: default; }
.qv-step-indicator {
  font-size: 13px;
  color: #6b7585;
  min-width: 48px;
  text-align: center;
  font-variant-numeric: tabular-nums;
}
