/* MATHE & PHYSIK-SPHÄRE – Eigene Styles
   ================================================================
   Farbschema: accent-mathe (#22c55e) – grün
   Aufbau analog zu weltraum.css, aber grüne Variante
   ================================================================ */

/* ── Topic Float-Layout (Magazin-Stil) ── */
.topic-float-right {
  float: right;
  width: 100%;
  max-width: 300px;
  margin: 3rem 0 1.5rem 1.5rem;
  overflow: hidden;
}

.topic-float-left {
  float: left;
  width: 100%;
  max-width: 300px;
  margin: 3rem 1.5rem 1.5rem 0;
  overflow: hidden;
}

.topic-float-right .topic-visual-inner,
.topic-float-left .topic-visual-inner {
  width: 100%;
  height: 16rem;
  border-radius: 1.5rem;
  overflow: hidden;
  border: 1px solid rgba(34, 197, 94, 0.15);
  position: relative;
  box-shadow: 0 0 30px rgba(34, 197, 94, 0.1);
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.topic-visual-inner:hover {
  border-color: rgba(34, 197, 94, 0.3);
  box-shadow: 0 0 40px rgba(34, 197, 94, 0.2);
}

.topic-clear {
  clear: both;
}

@media (min-width: 1024px) {
  .topic-float-right .topic-visual-inner,
  .topic-float-left .topic-visual-inner {
    height: 20rem;
  }
}

@media (max-width: 767px) {
  .topic-float-right,
  .topic-float-left {
    float: none;
    max-width: 100%;
    margin: 0 0 1.5rem 0;
  }

  .topic-float-right .topic-visual-inner,
  .topic-float-left .topic-visual-inner {
    height: 16rem;
  }
}

/* ── Mathe-Topic Hover-Effekt ── */
.mathe-topic {
  scroll-margin-top: 140px;
  display: flow-root;
  transition: transform 0.3s ease, opacity 0.6s ease;
}

.mathe-topic:hover {
  transform: translateY(-2px);
}

/* ── Scroll-Animationen ── */
.mathe-topic-hidden {
  opacity: 0;
  transform: translateY(30px);
}

.mathe-topic-visible {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fact-card-hidden {
  opacity: 0;
  transform: translateY(20px);
}

.fact-card-visible {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

/* ═══════════════════════════════════════════════════════════
   VISUALISIERUNG: Rechtwinkliges Dreieck (Pythagoras) – SVG
   ═══════════════════════════════════════════════════════════ */
.triangle-visual {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(ellipse at center, #0a1a0e 0%, #060f08 100%);
  overflow: hidden;
}

.triangle-svg {
  width: 260px;
  height: 210px;
  max-width: 90%;
  height: auto;
  filter: drop-shadow(0 0 12px rgba(34, 197, 94, 0.25));
  animation: triangle-svg-pulse 4s ease-in-out infinite;
}

@keyframes triangle-svg-pulse {
  0%, 100% { filter: drop-shadow(0 0 12px rgba(34, 197, 94, 0.25)); }
  50% { filter: drop-shadow(0 0 18px rgba(34, 197, 94, 0.4)); }
}

@media (max-width: 768px) {
  .triangle-svg {
    width: 210px;
  }
}

@media (max-width: 480px) {
  .triangle-svg {
    width: 170px;
  }
}

/* ═══════════════════════════════════════════════════════════
   VISUALISIERUNG: Kraft-Pfeil (Physik)
   ═══════════════════════════════════════════════════════════ */
.force-visual {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(ellipse at center, #0a1a0e 0%, #060f08 100%);
  overflow: hidden;
}

.force-stage {
  position: relative;
  width: 260px;
  height: 200px;
}

/* Der Block / das Objekt */
.force-block {
  position: absolute;
  bottom: 50px;
  left: 90px;
  width: 80px;
  height: 80px;
  background: linear-gradient(135deg, #1a3a20 0%, #0e2414 100%);
  border: 2px solid rgba(34, 197, 94, 0.4);
  border-radius: 8px;
  box-shadow: 0 0 20px rgba(34, 197, 94, 0.2), inset 0 -4px 8px rgba(0, 0, 0, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.5rem;
  color: #4ade80;
  animation: force-block-pulse 3s ease-in-out infinite;
}

@keyframes force-block-pulse {
  0%, 100% { transform: translateX(0); }
  50% { transform: translateX(4px); }
}

/* Der Kraft-Pfeil */
.force-arrow {
  position: absolute;
  bottom: 90px;
  left: 175px;
  width: 70px;
  height: 4px;
  background: linear-gradient(to right, #22c55e, #4ade80);
  box-shadow: 0 0 10px rgba(34, 197, 94, 0.6);
  border-radius: 2px;
  animation: arrow-extend 2s ease-in-out infinite;
}

.force-arrow::after {
  content: '';
  position: absolute;
  right: -2px;
  top: 50%;
  transform: translateY(-50%);
  width: 0;
  height: 0;
  border-left: 14px solid #4ade80;
  border-top: 10px solid transparent;
  border-bottom: 10px solid transparent;
  filter: drop-shadow(0 0 6px rgba(74, 222, 128, 0.6));
}

@keyframes arrow-extend {
  0%, 100% { width: 70px; opacity: 0.9; }
  50% { width: 85px; opacity: 1; }
}

/* Beschriftung F */
.force-label-f {
  position: absolute;
  bottom: 110px;
  left: 210px;
  font-weight: 800;
  font-size: 1.5rem;
  color: #22c55e;
  text-shadow: 0 0 10px rgba(34, 197, 94, 0.6);
}

/* Boden / Untergrund */
.force-ground {
  position: absolute;
  bottom: 44px;
  left: 30px;
  right: 30px;
  height: 3px;
  background: linear-gradient(to right, transparent, rgba(74, 222, 128, 0.4), transparent);
  border-radius: 2px;
}

.force-ground::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 0;
  right: 0;
  height: 12px;
  background: repeating-linear-gradient(
    -45deg,
    transparent 0px,
    transparent 4px,
    rgba(74, 222, 128, 0.15) 4px,
    rgba(74, 222, 128, 0.15) 6px
  );
}

/* (Formel F = m · a aus der Animation entfernt – wird im Fließtext hervorgehoben) */

@media (max-width: 768px) {
  .force-stage {
    transform: scale(0.8);
  }
}

@media (max-width: 480px) {
  .force-stage {
    transform: scale(0.65);
  }
}

/* ═══════════════════════════════════════════════════════════
   SPECIAL-HTML: Pythagoras Formel-Box
   ═══════════════════════════════════════════════════════════ */
.pythagoras-box {
  background: rgba(34, 197, 94, 0.05);
  border: 1px solid rgba(34, 197, 94, 0.12);
  border-radius: 1rem;
  padding: 1.25rem 1.5rem;
  margin-bottom: 1.5rem;
}

.pythagoras-intro {
  font-weight: 700;
  font-size: 0.875rem;
  color: #86efac;
  margin-bottom: 1rem;
}

.pythagoras-formula {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  font-size: 1.75rem;
  font-weight: 800;
  margin-bottom: 1.25rem;
}

.pythagoras-term {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  background: rgba(34, 197, 94, 0.08);
  border: 1px solid rgba(34, 197, 94, 0.15);
  border-radius: 0.75rem;
  padding: 0.5rem 0.875rem;
  transition: all 0.2s ease;
}

.pythagoras-term:hover {
  background: rgba(34, 197, 94, 0.15);
  border-color: rgba(34, 197, 94, 0.3);
  transform: translateY(-2px);
}

.pythagoras-term-letter {
  color: #22c55e;
  font-weight: 800;
  font-size: 1.5rem;
}

.pythagoras-term-sup {
  color: #4ade80;
  font-size: 1rem;
  font-weight: 700;
  vertical-align: super;
}

.pythagoras-op {
  color: #86efac;
  font-size: 1.5rem;
  font-weight: 700;
}

/* ═══════════════════════════════════════════════════════════
   SPECIAL-HTML: Kraft Formel-Box (F = m · a)
   ═══════════════════════════════════════════════════════════ */
.force-formula-box {
  background: rgba(34, 197, 94, 0.05);
  border: 1px solid rgba(34, 197, 94, 0.12);
  border-radius: 1rem;
  padding: 1.25rem 1.5rem;
  margin-bottom: 1.5rem;
}

.force-formula-intro {
  font-weight: 700;
  font-size: 0.875rem;
  color: #86efac;
  margin-bottom: 1rem;
}

.force-formula {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  font-size: 1.75rem;
  font-weight: 800;
  margin-bottom: 1rem;
}

.force-term {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  background: rgba(34, 197, 94, 0.08);
  border: 1px solid rgba(34, 197, 94, 0.15);
  border-radius: 0.75rem;
  padding: 0.5rem 0.875rem;
  transition: all 0.2s ease;
}

.force-term:hover {
  background: rgba(34, 197, 94, 0.15);
  border-color: rgba(34, 197, 94, 0.3);
  transform: translateY(-2px);
}

.force-term-letter {
  color: #22c55e;
  font-weight: 800;
  font-size: 1.5rem;
}

.force-op {
  color: #86efac;
  font-size: 1.5rem;
  font-weight: 700;
}

.force-formula-legend {
  text-align: center;
  font-size: 0.875rem;
  color: #86efac;
  font-weight: 600;
  margin-bottom: 0;
}

/* ── Zwischenüberschriften im Fließtext (Kraft-Thema) ── */
.mathe-subheading {
  font-size: 1.25rem;
  font-weight: 800;
  color: #86efac;
  margin: 1.75rem 0 0.75rem;
  letter-spacing: -0.01em;
}

.mathe-subheading:first-of-type {
  margin-top: 0.5rem;
}

/* ── Formel-Legende als Liste (F = m · a Erklärung) ── */
.force-formula-legend-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 1rem;
}

.force-formula-legend-item {
  display: flex;
  align-items: flex-start;
  gap: 0.875rem;
  background: rgba(34, 197, 94, 0.06);
  border: 1px solid rgba(34, 197, 94, 0.12);
  border-radius: 0.75rem;
  padding: 0.75rem 1rem;
  transition: all 0.2s ease;
}

.force-formula-legend-item:hover {
  background: rgba(34, 197, 94, 0.1);
  border-color: rgba(34, 197, 94, 0.25);
}

.force-formula-legend-letter {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  flex-shrink: 0;
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.25);
  border-radius: 0.5rem;
  font-size: 1.25rem;
  font-weight: 800;
  color: #22c55e;
  text-shadow: 0 0 8px rgba(34, 197, 94, 0.4);
}

.force-formula-legend-text {
  font-size: 0.9375rem;
  color: #cbd5e1;
  line-height: 1.5;
  align-self: center;
}

.force-formula-legend-text b {
  color: #86efac;
  font-weight: 700;
}

@media (max-width: 480px) {
  .force-formula-legend-item {
    flex-direction: column;
    gap: 0.5rem;
  }

  .force-formula-legend-text {
    align-self: stretch;
  }
}

.pythagoras-examples {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 0.75rem;
}

.pythagoras-example {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  background: rgba(34, 197, 94, 0.06);
  border: 1px solid rgba(34, 197, 94, 0.1);
  border-radius: 0.75rem;
  padding: 0.875rem 1rem;
  transition: all 0.2s ease;
}

.pythagoras-example:hover {
  background: rgba(34, 197, 94, 0.12);
  border-color: rgba(34, 197, 94, 0.25);
}

.pythagoras-example-title {
  font-weight: 700;
  font-size: 0.875rem;
  color: #86efac;
}

.pythagoras-example-triple {
  font-size: 1.05rem;
  color: #4ade80;
  font-weight: 800;
  letter-spacing: 0.05em;
}

.pythagoras-example-calc {
  font-size: 0.9375rem;
  color: #cbd5e1;
  font-weight: 600;
}

.pythagoras-example-result {
  font-size: 1rem;
  color: #22c55e;
  font-weight: 800;
}

/* ═══════════════════════════════════════════════════════════
   SPECIAL-HTML: Pythagoras-Anwendungsbeispiele (Einsatzwecke)
   ═══════════════════════════════════════════════════════════ */
.pythagoras-beispiele {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1rem;
  margin-top: 1rem;
  margin-bottom: 1.5rem;
}

.pythagoras-beispiel {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  background: rgba(34, 197, 94, 0.06);
  border: 1px solid rgba(34, 197, 94, 0.14);
  border-radius: 1rem;
  padding: 1.25rem 1.25rem 1.125rem;
  transition: all 0.2s ease;
}

.pythagoras-beispiel:hover {
  background: rgba(34, 197, 94, 0.1);
  border-color: rgba(34, 197, 94, 0.3);
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(34, 197, 94, 0.08);
}

.pythagoras-beispiel-titel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  font-weight: 800;
  font-size: 1.125rem;
  color: #86efac;
}

.pythagoras-beispiel-tag {
  font-size: 0.6875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #4ade80;
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.2);
  border-radius: 999px;
  padding: 0.15rem 0.55rem;
}

.pythagoras-beispiel-svg {
  display: flex;
  justify-content: center;
  align-items: center;
  background: rgba(34, 197, 94, 0.04);
  border: 1px solid rgba(34, 197, 94, 0.1);
  border-radius: 0.75rem;
  padding: 0.5rem;
}

.pythagoras-beispiel-svg svg {
  width: 100%;
  max-width: 180px;
  height: auto;
}

.pythagoras-beispiel-task {
  font-size: 0.9375rem;
  color: #cbd5e1;
  line-height: 1.5;
}

.pythagoras-beispiel-steps {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  margin: 0.1rem 0;
}

.pythagoras-beispiel-step {
  font-size: 0.9375rem;
  color: #e2e8f0;
  line-height: 1.5;
  background: rgba(34, 197, 94, 0.08);
  border-left: 3px solid rgba(34, 197, 94, 0.4);
  border-radius: 0.4rem;
  padding: 0.4rem 0.65rem;
}

.pythagoras-beispiel-step b {
  color: #86efac;
  font-weight: 700;
}

.pythagoras-beispiel-result {
  font-size: 1rem;
  color: #22c55e;
  font-weight: 800;
  background: rgba(34, 197, 94, 0.08);
  border-radius: 0.5rem;
  padding: 0.5rem 0.65rem;
}

/* Inline-Hervorhebung für Rechnungen in Karussell-Fakten */
.rechen-inline {
  display: inline-block;
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.25);
  border-radius: 0.4rem;
  padding: 0.1rem 0.4rem;
  font-weight: 700;
  color: #bbf7d0;
  font-variant-numeric: tabular-nums;
}

/* Durchgestrichene Terme bei der Formel-Umstellung */
.rechen-strike {
  text-decoration: line-through;
  text-decoration-color: rgba(248, 113, 113, 0.75);
  text-decoration-thickness: 2px;
  color: #94a3b8;
  opacity: 0.7;
}

/* Block für einen Umstellungs-Schritt (Ausgang → Ergebnis → Wurzel) */
.umstell-schritt {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.5rem;
  background: rgba(34, 197, 94, 0.05);
  border: 1px solid rgba(34, 197, 94, 0.12);
  border-radius: 0.6rem;
  padding: 0.75rem 1rem;
}

.umstell-zeile {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.umstell-op {
  color: #f87171;
  font-weight: 800;
  font-size: 0.95rem;
  font-variant-numeric: tabular-nums;
}

.umstell-wurzel {
  font-size: 0.9375rem;
  color: #cbd5e1;
  font-weight: 600;
  margin-top: 0.15rem;
}

/* ═══════════════════════════════════════════════════════════
   SPECIAL-HTML: Kräfte-Vergleichsbalken
   ═══════════════════════════════════════════════════════════ */
.force-scale {
  background: rgba(34, 197, 94, 0.05);
  border: 1px solid rgba(34, 197, 94, 0.12);
  border-radius: 1rem;
  padding: 1.25rem 1.5rem;
}

.force-scale-intro {
  font-weight: 700;
  font-size: 0.875rem;
  color: #86efac;
  margin-bottom: 1rem;
}

.force-scale-bars {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.force-bar {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.force-bar-label {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  min-width: 160px;
  flex-shrink: 0;
}

.force-bar-emoji {
  font-size: 1.125rem;
  line-height: 1;
}

.force-bar-title {
  font-size: 0.9375rem;
  font-weight: 700;
  color: #86efac;
  white-space: nowrap;
}

.force-bar-track {
  flex: 1;
  height: 10px;
  background: rgba(34, 197, 94, 0.08);
  border-radius: 5px;
  overflow: hidden;
  border: 1px solid rgba(34, 197, 94, 0.1);
}

.force-bar-fill {
  height: 100%;
  border-radius: 5px;
  background: linear-gradient(to right, #22c55e, #16a34a);
  transition: width 1s ease;
  position: relative;
}

.force-bar-fill::after {
  content: '';
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 20px;
  background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.15));
  border-radius: 0 5px 5px 0;
}

.force-bar-fill-max {
  background: linear-gradient(to right, #22c55e, #15803d, #14532d);
  box-shadow: 0 0 8px rgba(21, 128, 61, 0.4);
}

.force-bar-desc {
  font-size: 0.8125rem;
  color: #94a3b8;
  min-width: 180px;
  white-space: nowrap;
  text-align: right;
  flex-shrink: 0;
}

.force-bar:hover .force-bar-fill {
  box-shadow: 0 0 12px rgba(34, 197, 94, 0.4);
}

.force-bar:hover .force-bar-fill-max {
  box-shadow: 0 0 16px rgba(21, 128, 61, 0.6);
}

@media (max-width: 768px) {
  .force-bar {
    flex-wrap: wrap;
    gap: 0.25rem;
  }

  .force-bar-label {
    min-width: unset;
    order: 1;
    width: 100%;
  }

  .force-bar-track {
    order: 2;
    width: 100%;
  }

  .force-bar-desc {
    order: 3;
    min-width: unset;
    text-align: left;
    white-space: normal;
    width: 100%;
  }
}

/* ═══════════════════════════════════════════════════════════
   FAKTEN-CAROUSEL (grüne Variante)
   ═══════════════════════════════════════════════════════════ */
.fact-carousel {
  position: relative;
  margin-bottom: 1.5rem;
  user-select: none;
}

.fact-carousel-viewport {
  position: relative;
  overflow: hidden;
  border-radius: 1rem;
  border: 1px solid rgba(34, 197, 94, 0.15);
  background: rgba(34, 197, 94, 0.06);
}

.fact-carousel-track {
  display: flex;
  gap: 0;
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.fact-carousel-slide {
  width: 100%;
  min-width: 100%;
  flex-shrink: 0;
  flex-grow: 0;
  padding: 0;
  box-sizing: border-box;
  align-self: stretch;
}

.planet-fact {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 24px 60px;
  background: rgba(34, 197, 94, 0.06);
  border: none;
  border-radius: 0;
  min-height: 140px;
  height: 100%;
  justify-content: center;
  box-sizing: border-box;
}

.planet-fact-label {
  font-weight: 700;
  font-size: 1.125rem;
  color: #86efac;
}

.planet-fact-value {
  font-size: 1rem;
  color: #cbd5e1;
  line-height: 1.7;
}

.fact-carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid rgba(34, 197, 94, 0.3);
  /* Performance: kein backdrop-filter – der Blur über scrollendem Inhalt
     (inkl. Sternenhimmel) ist in Firefox sehr teuer. */
  background: rgba(13, 15, 26, 0.95);
  color: #86efac;
  font-size: 1.125rem;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 5;
  line-height: 1;
}

.fact-carousel-btn:hover {
  background: rgba(34, 197, 94, 0.2);
  border-color: rgba(34, 197, 94, 0.5);
  box-shadow: 0 0 15px rgba(34, 197, 94, 0.3);
  transform: translateY(-50%) scale(1.1);
}

.fact-carousel-btn:active {
  transform: translateY(-50%) scale(0.95);
}

.fact-carousel-prev {
  left: 6px;
}

.fact-carousel-next {
  right: 6px;
}

.fact-carousel-btn:disabled {
  opacity: 0.3;
  cursor: default;
  transform: translateY(-50%);
  box-shadow: none;
}

.fact-carousel-btn:disabled:hover {
  background: rgba(13, 15, 26, 0.9);
  border-color: rgba(34, 197, 94, 0.3);
  transform: translateY(-50%);
  box-shadow: none;
}

.fact-carousel-footer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-top: 0.5rem;
  padding: 0.5rem 1rem;
  background: transparent;
}

.fact-carousel-dots {
  display: flex;
  gap: 6px;
  align-items: center;
}

.fact-carousel-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(34, 197, 94, 0.2);
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
  padding: 0;
}

.fact-carousel-dot:hover {
  background: rgba(34, 197, 94, 0.4);
}

.fact-carousel-dot.active {
  background: #22c55e;
  box-shadow: 0 0 8px rgba(34, 197, 94, 0.5);
  width: 10px;
  height: 10px;
}

.fact-carousel-counter {
  font-size: 0.75rem;
  color: #64748b;
  font-weight: 600;
  min-width: 40px;
  text-align: center;
}

.fact-carousel-swipe-hint {
  display: none;
  font-size: 0.6875rem;
  color: #475569;
  text-align: center;
  margin-top: 0.25rem;
  font-style: italic;
}

@media (max-width: 768px) {
  .fact-carousel-btn {
    width: 30px;
    height: 30px;
    font-size: 0.875rem;
  }

  .fact-carousel-prev {
    left: 4px;
  }

  .fact-carousel-next {
    right: 4px;
  }

  .planet-fact {
    padding: 18px 48px;
  }

  .planet-fact-label {
    font-size: 1rem;
  }

  .planet-fact-value {
    font-size: 0.9375rem;
  }

  .fact-carousel-swipe-hint {
    display: block;
  }
}

@media (hover: none) and (pointer: coarse) {
  .fact-carousel-swipe-hint {
    display: block;
  }
}

/* ═══════════════════════════════════════════════════════════
   FAKTEN-KARTEN
   ═══════════════════════════════════════════════════════════ */
.fact-card {
  background: rgba(34, 197, 94, 0.06);
  border: 1px solid rgba(34, 197, 94, 0.15);
  border-radius: 1rem;
  padding: 1.5rem;
  text-align: center;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.fact-card::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(34, 197, 94, 0.08) 0%, transparent 70%);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.fact-card:hover {
  border-color: rgba(34, 197, 94, 0.35);
  transform: translateY(-4px);
  box-shadow: 0 8px 30px rgba(34, 197, 94, 0.15);
}

.fact-card:hover::before {
  opacity: 1;
}

.fact-card-emoji {
  font-size: 2rem;
  margin-bottom: 0.75rem;
}

.fact-card-number {
  font-size: 1.75rem;
  font-weight: 800;
  color: #86efac;
  margin-bottom: 0.25rem;
  letter-spacing: -0.02em;
}

.fact-card-label {
  font-size: 0.9375rem;
  color: #cbd5e1;
  line-height: 1.5;
}

@media (max-width: 768px) {
  .fact-card-number {
    font-size: 1.375rem;
  }
}

@media (max-width: 480px) {
  .fact-card {
    padding: 1rem;
  }

  .fact-card-number {
    font-size: 1.25rem;
  }
}

/* ═══════════════════════════════════════════════════════════
   TAB-NAVIGATION
   ═══════════════════════════════════════════════════════════ */
.mathe-tab-nav {
  margin-bottom: 2rem;
}

.mathe-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
  padding: 0.5rem;
  background: rgba(34, 197, 94, 0.04);
  border: 1px solid rgba(34, 197, 94, 0.1);
  border-radius: 1rem;
}

.mathe-tab {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.625rem 1.25rem;
  border-radius: 0.75rem;
  font-weight: 700;
  font-size: 0.9375rem;
  color: #94a3b8;
  background: transparent;
  border: 1px solid transparent;
  transition: all 0.25s ease;
  text-decoration: none;
  white-space: nowrap;
}

.mathe-tab:hover {
  color: #86efac;
  background: rgba(34, 197, 94, 0.08);
}

.mathe-tab.active {
  color: #22c55e;
  background: rgba(34, 197, 94, 0.12);
  border-color: rgba(34, 197, 94, 0.3);
  box-shadow: 0 0 15px rgba(34, 197, 94, 0.2);
}

.mathe-tab-emoji {
  font-size: 1.125rem;
}

.mathe-tab-label {
  font-size: 0.9375rem;
}

@media (max-width: 640px) {
  .mathe-tabs {
    flex-direction: column;
    gap: 0.375rem;
  }

  .mathe-tab {
    justify-content: center;
    width: 100%;
  }
}

/* ═══════════════════════════════════════════════════════════
   START-BUTTON (Spiel-Platzhalter)
   ═══════════════════════════════════════════════════════════ */
.pr-start-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 1rem 2rem;
  margin: 2rem auto 0;
  width: fit-content;
  min-width: 300px;
  background: linear-gradient(135deg, #22c55e 0%, #16a34a 40%, #15803d 100%);
  border: none;
  color: #ffffff;
  border-radius: 1rem;
  font-weight: 800;
  font-size: 1.0625rem;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 0 20px rgba(34, 197, 94, 0.35), 0 4px 20px rgba(0, 0, 0, 0.3);
  position: relative;
  overflow: hidden;
  letter-spacing: 0.02em;
  animation: pr-btn-glow-pulse 2.5s ease-in-out infinite;
}

.pr-start-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, transparent 50%);
  pointer-events: none;
}

@keyframes pr-btn-glow-pulse {
  0%, 100% { box-shadow: 0 0 20px rgba(34, 197, 94, 0.35), 0 4px 20px rgba(0, 0, 0, 0.3); }
  50% { box-shadow: 0 0 35px rgba(34, 197, 94, 0.55), 0 6px 25px rgba(0, 0, 0, 0.35); }
}

@media (max-width: 768px) {
  .pr-start-btn {
    animation: none;
  }
}

.pr-start-btn:hover {
  background: linear-gradient(135deg, #32d36e 0%, #1ab34e 40%, #16903a 100%);
  transform: translateY(-3px) scale(1.03);
  box-shadow: 0 0 40px rgba(34, 197, 94, 0.55), 0 8px 30px rgba(0, 0, 0, 0.4);
  animation: none;
}

.pr-start-btn:active {
  transform: translateY(1px) scale(0.98);
  box-shadow: 0 0 15px rgba(34, 197, 94, 0.3), 0 2px 10px rgba(0, 0, 0, 0.2);
  transition: all 0.1s ease;
}

/* ═══════════════════════════════════════════════════════════
   MODAL (Platzhalter "bald verfügbar")
   ═══════════════════════════════════════════════════════════ */
.pr-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0);
  backdrop-filter: blur(0px);
  transition: background 0.35s ease, backdrop-filter 0.35s ease;
  padding: 1rem;
}

.pr-modal-overlay.pr-modal-visible {
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(6px);
}

.pr-modal-overlay.pr-modal-hiding {
  background: rgba(0, 0, 0, 0);
  backdrop-filter: blur(0px);
}

.pr-modal-content {
  position: relative;
  width: 100%;
  max-width: 560px;
  max-height: 90vh;
  overflow-y: auto;
  background: #0d1a10;
  border: 1px solid rgba(34, 197, 94, 0.25);
  border-radius: 1.25rem;
  box-shadow: 0 0 40px rgba(34, 197, 94, 0.15), 0 25px 60px rgba(0, 0, 0, 0.5);
  transform: scale(0.9) translateY(20px);
  opacity: 0;
  transition: transform 0.35s ease, opacity 0.35s ease;
}

.pr-modal-overlay.pr-modal-visible .pr-modal-content {
  transform: scale(1) translateY(0);
  opacity: 1;
}

.pr-modal-overlay.pr-modal-hiding .pr-modal-content {
  transform: scale(0.9) translateY(20px);
  opacity: 0;
}

.pr-modal-content::-webkit-scrollbar {
  width: 6px;
}

.pr-modal-content::-webkit-scrollbar-track {
  background: transparent;
}

.pr-modal-content::-webkit-scrollbar-thumb {
  background: rgba(34, 197, 94, 0.2);
  border-radius: 3px;
}

.pr-modal-content::-webkit-scrollbar-thumb:hover {
  background: rgba(34, 197, 94, 0.35);
}

.pr-intro {
  background: rgba(34, 197, 94, 0.05);
  border: 1px solid rgba(34, 197, 94, 0.15);
  border-radius: 1rem;
  padding: 1.5rem;
  text-align: center;
  animation: pr-fade-in 0.4s ease;
}

@keyframes pr-fade-in {
  from { opacity: 0; transform: translateY(15px); }
  to { opacity: 1; transform: translateY(0); }
}

.pr-intro-header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.pr-intro-emoji {
  font-size: 1.75rem;
}

.pr-intro-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: #86efac;
  margin: 0;
}

.pr-intro-desc {
  font-size: 0.875rem;
  color: #94a3b8;
  line-height: 1.5;
  margin-bottom: 1rem;
}

.pr-btn {
  padding: 0.625rem 1.25rem;
  border-radius: 0.75rem;
  font-weight: 700;
  font-size: 0.875rem;
  cursor: pointer;
  transition: all 0.2s ease;
  border: none;
}

.pr-btn-start {
  background: linear-gradient(135deg, #22c55e, #16a34a);
  color: white;
  box-shadow: 0 0 15px rgba(34, 197, 94, 0.3);
}

.pr-btn-start:hover {
  transform: scale(1.05);
  box-shadow: 0 0 25px rgba(34, 197, 94, 0.5);
}

/* ═══════════════════════════════════════════════════════════
   FAB: Zurück nach oben
   ═══════════════════════════════════════════════════════════ */
.mathe-fab {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: linear-gradient(135deg, #22c55e, #16a34a);
  border: none;
  color: white;
  font-size: 1.25rem;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(34, 197, 94, 0.4), 0 0 0 1px rgba(34, 197, 94, 0.2);
  opacity: 0;
  transform: scale(0.5);
  transition: all 0.3s ease;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
}

.mathe-fab.mathe-fab-visible {
  opacity: 1;
  transform: scale(1);
}

.mathe-fab:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 30px rgba(34, 197, 94, 0.6), 0 0 0 1px rgba(34, 197, 94, 0.3);
}

@media (max-width: 768px) {
  .mathe-fab {
    bottom: 1rem;
    right: 1rem;
    width: 42px;
    height: 42px;
  }
}

/* ═══════════════════════════════════════════════════════════
   BUTTON-REIHE (Spiel + Rechner nebeneinander)
   ═══════════════════════════════════════════════════════════ */
.pr-button-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin: 2rem auto 0;
  max-width: 720px;
}

.pr-button-row .pr-start-btn {
  margin: 0;
  min-width: 260px;
}

/* ── Rechner-Button (Secondary / Outline-Stil) ── */
.pr-rechner-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 1rem 2rem;
  width: fit-content;
  min-width: 260px;
  background: transparent;
  border: 2px solid rgba(34, 197, 94, 0.4);
  color: #4ade80;
  border-radius: 1rem;
  font-weight: 800;
  font-size: 1.0625rem;
  cursor: pointer;
  transition: all 0.3s ease;
  letter-spacing: 0.02em;
  position: relative;
  overflow: hidden;
}

.pr-rechner-btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.08) 0%, transparent 60%);
  pointer-events: none;
  transition: background 0.3s ease;
}

.pr-rechner-btn:hover {
  background: rgba(34, 197, 94, 0.1);
  border-color: rgba(34, 197, 94, 0.6);
  color: #86efac;
  transform: translateY(-3px) scale(1.03);
  box-shadow: 0 0 30px rgba(34, 197, 94, 0.25), 0 8px 30px rgba(0, 0, 0, 0.3);
}

.pr-rechner-btn:hover::before {
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.15) 0%, transparent 60%);
}

.pr-rechner-btn:active {
  transform: translateY(1px) scale(0.98);
  box-shadow: 0 0 15px rgba(34, 197, 94, 0.2);
  transition: all 0.1s ease;
}

@media (max-width: 640px) {
  .pr-button-row {
    flex-direction: column;
  }

  .pr-button-row .pr-start-btn,
  .pr-rechner-btn {
    width: 100%;
    min-width: unset;
  }
}

/* ═══════════════════════════════════════════════════════════
   RECHNER-MODAL
   ═══════════════════════════════════════════════════════════ */
.rechner-modal-content {
  max-width: 600px;
  padding: 0;
}

/* Header */
.rechner-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid rgba(34, 197, 94, 0.12);
  background: rgba(34, 197, 94, 0.04);
  border-radius: 1.25rem 1.25rem 0 0;
}

.rechner-modal-titel {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 1.25rem;
  font-weight: 800;
  color: #86efac;
}

.rechner-modal-emoji {
  font-size: 1.5rem;
}

.rechner-modal-close {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid rgba(34, 197, 94, 0.2);
  background: transparent;
  color: #94a3b8;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.rechner-modal-close:hover {
  background: rgba(34, 197, 94, 0.15);
  border-color: rgba(34, 197, 94, 0.4);
  color: #86efac;
  transform: rotate(90deg);
}

/* Beschreibung */
.rechner-modal-desc {
  padding: 1rem 1.5rem 0.5rem;
  font-size: 0.875rem;
  color: #94a3b8;
  line-height: 1.5;
  margin: 0;
}

/* Eingabefelder */
.rechner-felder {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.875rem;
  padding: 1rem 1.5rem 0.5rem;
}

.rechner-feld {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  background: rgba(34, 197, 94, 0.04);
  border: 1px solid rgba(34, 197, 94, 0.12);
  border-radius: 0.875rem;
  padding: 0.875rem 0.875rem 1rem;
  transition: all 0.25s ease;
}

.rechner-feld:focus-within {
  border-color: rgba(34, 197, 94, 0.4);
  background: rgba(34, 197, 94, 0.08);
  box-shadow: 0 0 15px rgba(34, 197, 94, 0.12);
}

.rechner-feld-berechnet {
  border-color: rgba(34, 197, 94, 0.35);
  background: rgba(34, 197, 94, 0.1);
  box-shadow: 0 0 12px rgba(34, 197, 94, 0.15);
}

.rechner-feld-label {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.15rem;
}

.rechner-feld-letter {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--feld-farbe, #4ade80);
  line-height: 1;
  text-shadow: 0 0 8px color-mix(in srgb, var(--feld-farbe, #4ade80) 40%, transparent);
}

.rechner-feld-desc {
  font-size: 0.6875rem;
  color: #64748b;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.rechner-feld-input {
  width: 100%;
  padding: 0.6rem 0.5rem;
  background: rgba(13, 26, 16, 0.6);
  border: 1px solid rgba(34, 197, 94, 0.2);
  border-radius: 0.6rem;
  color: #e2e8f0;
  font-size: 1.125rem;
  font-weight: 700;
  text-align: center;
  font-variant-numeric: tabular-nums;
  transition: all 0.2s ease;
  outline: none;
  -moz-appearance: textfield;
}

.rechner-feld-input::-webkit-outer-spin-button,
.rechner-feld-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.rechner-feld-input::placeholder {
  color: #475569;
  font-weight: 400;
}

.rechner-feld-input:focus {
  border-color: rgba(34, 197, 94, 0.5);
  background: rgba(13, 26, 16, 0.9);
  box-shadow: 0 0 10px rgba(34, 197, 94, 0.2);
}

.rechner-feld-input:disabled {
  color: #22c55e;
  background: rgba(34, 197, 94, 0.12);
  border-color: rgba(34, 197, 94, 0.3);
  cursor: not-allowed;
}

/* Ergebnis-Bereich */
.rechner-ergebnis {
  margin: 0.5rem 1.5rem 0;
  min-height: 3rem;
}

.rechner-ergebnis-hint {
  text-align: center;
  font-size: 0.875rem;
  color: #64748b;
  font-style: italic;
  padding: 1rem 0.5rem;
  line-height: 1.5;
}

.rechner-ergebnis-error {
  text-align: center;
  font-size: 0.875rem;
  color: #fca5a5;
  font-weight: 600;
  padding: 1rem 0.5rem;
  background: rgba(239, 68, 68, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.2);
  border-radius: 0.6rem;
  line-height: 1.5;
}

.rechner-ergebnis-formel {
  font-size: 0.875rem;
  color: #94a3b8;
  margin-bottom: 0.75rem;
  text-align: center;
}

/* Schritte */
.rechner-schritte {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-bottom: 1rem;
}

.rechner-schritt {
  display: flex;
  align-items: baseline;
  gap: 0.6rem;
  background: rgba(34, 197, 94, 0.06);
  border-left: 3px solid rgba(34, 197, 94, 0.35);
  border-radius: 0.4rem;
  padding: 0.5rem 0.7rem;
  animation: rechner-schritt-fade 0.35s ease;
}

@keyframes rechner-schritt-fade {
  from { opacity: 0; transform: translateX(-8px); }
  to { opacity: 1; transform: translateX(0); }
}

.rechner-schritt-label {
  font-size: 0.75rem;
  font-weight: 700;
  color: #86efac;
  white-space: nowrap;
  flex-shrink: 0;
  min-width: 5.5rem;
}

.rechner-schritt-rechnung {
  font-size: 0.9375rem;
  color: #e2e8f0;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  line-height: 1.4;
}

.rechner-schritt-highlight {
  background: rgba(34, 197, 94, 0.14);
  border-left-color: #22c55e;
  box-shadow: 0 0 12px rgba(34, 197, 94, 0.15);
}

.rechner-schritt-highlight .rechner-schritt-rechnung {
  color: #bbf7d0;
  font-weight: 800;
}

/* Endergebnis */
.rechner-ergebnis-final {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.15) 0%, rgba(22, 163, 74, 0.1) 100%);
  border: 1px solid rgba(34, 197, 94, 0.3);
  border-radius: 0.875rem;
  padding: 1rem 1.25rem;
  margin-top: 0.5rem;
  animation: rechner-ergebnis-pop 0.4s ease;
}

@keyframes rechner-ergebnis-pop {
  from { opacity: 0; transform: scale(0.92); }
  to { opacity: 1; transform: scale(1); }
}

.rechner-ergebnis-final-label {
  font-size: 1.5rem;
  font-weight: 800;
  color: #4ade80;
}

.rechner-ergebnis-final-wert {
  font-size: 2rem;
  font-weight: 800;
  color: #22c55e;
  font-variant-numeric: tabular-nums;
  text-shadow: 0 0 12px rgba(34, 197, 94, 0.4);
}

/* Footer */
.rechner-modal-footer {
  display: flex;
  justify-content: center;
  padding: 0.75rem 1.5rem 1.5rem;
}

.rechner-reset-btn {
  background: transparent;
  border: 1px solid rgba(34, 197, 94, 0.25);
  color: #94a3b8;
}

.rechner-reset-btn:hover {
  background: rgba(34, 197, 94, 0.1);
  border-color: rgba(34, 197, 94, 0.4);
  color: #86efac;
  transform: scale(1.05);
}

/* Responsive */
@media (max-width: 560px) {
  .rechner-felder {
    grid-template-columns: 1fr;
    gap: 0.6rem;
  }

  .rechner-feld {
    flex-direction: row;
    align-items: center;
    gap: 0.875rem;
    padding: 0.6rem 0.875rem;
  }

  .rechner-feld-label {
    flex-direction: row;
    align-items: center;
    gap: 0.4rem;
    flex-shrink: 0;
    min-width: 5rem;
  }

  .rechner-feld-letter {
    font-size: 1.25rem;
  }

  .rechner-feld-desc {
    font-size: 0.625rem;
  }

  .rechner-feld-input {
    flex: 1;
  }

  .rechner-schritt {
    flex-direction: column;
    gap: 0.2rem;
  }

  .rechner-schritt-label {
    min-width: unset;
  }

  .rechner-ergebnis-final-wert {
    font-size: 1.5rem;
  }
}
/* ═══════════════════════════════════════════════════════════
   RECHNER: EINHEITEN-BADGES (Kraft-Rechner)
   ═══════════════════════════════════════════════════════════ */

/* Zeile mit Buchstabe + Einheit nebeneinander */
.rechner-feld-letter-row {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
}

/* Einheiten-Badge neben dem Feld-Label */
.rechner-feld-einheit {
  display: inline-flex;
  align-items: center;
  font-size: 0.625rem;
  font-weight: 700;
  color: #64748b;
  background: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.2);
  border-radius: 0.3rem;
  padding: 0.05rem 0.3rem;
  line-height: 1.4;
  letter-spacing: 0.02em;
  text-transform: none;
}

/* Einheit neben dem Endergebnis */
.rechner-ergebnis-final-einheit {
  font-size: 1.25rem;
  font-weight: 700;
  color: #4ade80;
  opacity: 0.85;
}

@media (max-width: 560px) {
  .rechner-feld-einheit {
    font-size: 0.5625rem;
  }

  .rechner-ergebnis-final-einheit {
    font-size: 1rem;
  }
}

/* ═══════════════════════════════════════════════════════════ */
/* ── Modal-Basis (pr-modal-* Klassen, grünes Farbschema) ── */
/* ═══════════════════════════════════════════════════════════ */

.pr-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0);
  backdrop-filter: blur(0px);
  transition: background 0.35s ease, backdrop-filter 0.35s ease;
  padding: 1rem;
}

.pr-modal-overlay.pr-modal-visible {
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(6px);
}

.pr-modal-overlay.pr-modal-hiding {
  background: rgba(0, 0, 0, 0);
  backdrop-filter: blur(0px);
}

.pr-modal-content {
  position: relative;
  width: 100%;
  max-width: 560px;
  max-height: 90vh;
  overflow-y: auto;
  background: #0d0f1a;
  border: 1px solid rgba(74, 222, 128, 0.25);
  border-radius: 1.25rem;
  box-shadow: 0 0 40px rgba(74, 222, 128, 0.15), 0 25px 60px rgba(0, 0, 0, 0.5);
  transform: scale(0.9) translateY(20px);
  opacity: 0;
  transition: transform 0.35s ease, opacity 0.35s ease;
}

.pr-modal-overlay.pr-modal-visible .pr-modal-content {
  transform: scale(1) translateY(0);
  opacity: 1;
}

.pr-modal-overlay.pr-modal-hiding .pr-modal-content {
  transform: scale(0.9) translateY(20px);
  opacity: 0;
}

.pr-modal-content::-webkit-scrollbar {
  width: 6px;
}

.pr-modal-content::-webkit-scrollbar-track {
  background: transparent;
}

.pr-modal-content::-webkit-scrollbar-thumb {
  background: rgba(74, 222, 128, 0.2);
  border-radius: 3px;
}

.pr-modal-content::-webkit-scrollbar-thumb:hover {
  background: rgba(74, 222, 128, 0.35);
}

/* ── Intro ── */
.pr-intro {
  background: rgba(74, 222, 128, 0.05);
  border: 1px solid rgba(74, 222, 128, 0.15);
  border-radius: 1rem;
  padding: 1.5rem;
  text-align: center;
  animation: pr-fade-in 0.4s ease;
}

@keyframes pr-fade-in {
  from { opacity: 0; transform: translateY(15px); }
  to { opacity: 1; transform: translateY(0); }
}

.pr-intro-header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.pr-intro-emoji {
  font-size: 1.75rem;
}

.pr-intro-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: #4ade80;
  margin: 0;
}

.pr-intro-desc {
  font-size: 0.875rem;
  color: #94a3b8;
  line-height: 1.5;
  margin-bottom: 1rem;
}

.pr-intro-scoring {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  justify-content: center;
  font-size: 0.75rem;
  color: #94a3b8;
  margin-bottom: 1.25rem;
}

.pr-intro-actions {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* ── Buttons ── */
.pr-btn {
  padding: 0.625rem 1.25rem;
  border-radius: 0.75rem;
  font-weight: 700;
  font-size: 0.875rem;
  cursor: pointer;
  transition: all 0.2s ease;
  border: none;
}

.pr-btn-start {
  background: linear-gradient(135deg, #22c55e, #16a34a);
  color: white;
  box-shadow: 0 0 15px rgba(74, 222, 128, 0.3);
}

.pr-btn-start:hover {
  transform: scale(1.05);
  box-shadow: 0 0 25px rgba(74, 222, 128, 0.5);
}

.pr-btn-cancel,
.pr-btn-finish {
  background: rgba(74, 222, 128, 0.1);
  border: 1px solid rgba(74, 222, 128, 0.25);
  color: #4ade80;
}

.pr-btn-cancel:hover,
.pr-btn-finish:hover {
  background: rgba(74, 222, 128, 0.2);
}

.pr-btn-restart {
  background: linear-gradient(135deg, #22c55e, #16a34a);
  color: white;
}

.pr-btn-restart:hover {
  transform: scale(1.05);
  box-shadow: 0 0 20px rgba(74, 222, 128, 0.4);
}

/* ── Playing ── */
.pr-playing {
  background: rgba(74, 222, 128, 0.05);
  border: 1px solid rgba(74, 222, 128, 0.15);
  border-radius: 1rem;
  padding: 1.25rem;
  animation: pr-fade-in 0.3s ease;
}

/* ── Ergebnis ── */
.pr-result {
  background: rgba(74, 222, 128, 0.05);
  border: 1px solid rgba(74, 222, 128, 0.15);
  border-radius: 1rem;
  padding: 1.5rem;
  text-align: center;
  animation: pr-fade-in 0.4s ease;
}

.pr-result-header {
  margin-bottom: 0.75rem;
}

.pr-result-emoji {
  font-size: 2rem;
  display: block;
  margin-bottom: 0.25rem;
}

.pr-result-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: #4ade80;
  margin: 0;
}

.pr-result-stars {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.pr-star {
  font-size: 1.75rem;
  transition: all 0.3s ease;
}

.pr-star-earned {
  animation: pr-star-pop 0.4s ease;
}

.pr-star-empty {
  opacity: 0.25;
}

@keyframes pr-star-pop {
  0% { transform: scale(0); }
  60% { transform: scale(1.3); }
  100% { transform: scale(1); }
}

.pr-result-score {
  margin-bottom: 1rem;
}

.pr-result-score-num {
  display: block;
  font-size: 2.5rem;
  font-weight: 800;
  color: #4ade80;
  line-height: 1;
}

.pr-result-score-label {
  font-size: 0.8125rem;
  color: #64748b;
  font-weight: 600;
}

.pr-result-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
  margin-bottom: 1rem;
  text-align: left;
}

.pr-result-stat {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0.75rem;
  background: rgba(74, 222, 128, 0.06);
  border: 1px solid rgba(74, 222, 128, 0.1);
  border-radius: 0.5rem;
}

.pr-result-stat-label {
  font-size: 0.75rem;
  color: #64748b;
}

.pr-result-stat-value {
  font-size: 0.8125rem;
  font-weight: 700;
  color: #4ade80;
}

.pr-result-stat-bonus .pr-result-stat-value {
  color: #fbbf24;
}

.pr-result-xp {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.625rem 1.25rem;
  background: linear-gradient(135deg, rgba(74, 222, 128, 0.15), rgba(74, 222, 128, 0.05));
  border: 1px solid rgba(74, 222, 128, 0.3);
  border-radius: 0.75rem;
  margin-bottom: 1.25rem;
  animation: pr-xp-glow 2s ease-in-out infinite;
}

@keyframes pr-xp-glow {
  0%, 100% { box-shadow: 0 0 10px rgba(74, 222, 128, 0.2); }
  50% { box-shadow: 0 0 20px rgba(74, 222, 128, 0.4); }
}

.pr-result-xp-icon {
  font-size: 1.25rem;
}

.pr-result-xp-text {
  font-size: 0.875rem;
  font-weight: 700;
  color: #4ade80;
}

.pr-result-actions {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
}

@media (max-width: 480px) {
  .pr-result-stats {
    grid-template-columns: 1fr;
  }
}

/* ═══════════════════════════════════════════════════════════ */
/* ── Pythagoras-Werkstatt Minispiel ── */
/* ═══════════════════════════════════════════════════════════ */

/* Modal-Content Override (grünes Farbschema) */
.pw-modal-content {
  background: linear-gradient(160deg, #0f1f15 0%, #0a1410 100%);
  border: 1px solid rgba(74, 222, 128, 0.15);
}

/* Scrollbar grün */
.pw-modal-content::-webkit-scrollbar-thumb {
  background: rgba(74, 222, 128, 0.2);
}
.pw-modal-content::-webkit-scrollbar-thumb:hover {
  background: rgba(74, 222, 128, 0.35);
}

/* ── Intro ── */
.pw-intro {
  background: rgba(74, 222, 128, 0.05);
}

.pw-intro-steps {
  background: rgba(74, 222, 128, 0.06);
  border: 1px solid rgba(74, 222, 128, 0.12);
  border-radius: 0.75rem;
  padding: 1rem;
  margin-bottom: 1rem;
}

.pw-intro-steps-title {
  font-size: 0.875rem;
  font-weight: 700;
  color: #4ade80;
  margin-bottom: 0.75rem;
}

.pw-intro-step {
  display: flex;
  align-items: flex-start;
  gap: 0.625rem;
  margin-bottom: 0.625rem;
}
.pw-intro-step:last-child { margin-bottom: 0; }

.pw-intro-step-num {
  flex-shrink: 0;
  width: 1.75rem;
  height: 1.75rem;
  border-radius: 50%;
  background: linear-gradient(135deg, #22c55e, #16a34a);
  color: #fff;
  font-size: 0.875rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.pw-intro-step-text {
  font-size: 0.8125rem;
  color: #cbd5e1;
  line-height: 1.5;
  padding-top: 0.15rem;
}

/* ── Start-Button grün ── */
.pw-btn-start {
  background: linear-gradient(135deg, #22c55e, #16a34a) !important;
}
.pw-btn-start:hover {
  background: linear-gradient(135deg, #4ade80, #22c55e) !important;
  transform: scale(1.05);
}

/* ── Top-Leiste ── */
.pw-topbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  justify-content: center;
  padding: 0.5rem 0.75rem;
  background: rgba(74, 222, 128, 0.06);
  border: 1px solid rgba(74, 222, 128, 0.1);
  border-radius: 0.5rem;
  margin-bottom: 0.75rem;
  font-size: 0.75rem;
}

.pw-topbar-round {
  color: #4ade80;
  font-weight: 700;
}

.pw-topbar-score {
  color: #fbbf24;
  font-weight: 600;
}

.pw-topbar-combo {
  color: #f97316;
  font-weight: 700;
  animation: pw-combo-pulse 0.4s ease;
}

@keyframes pw-combo-pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.2); }
  100% { transform: scale(1); }
}

.pw-topbar-timer {
  color: #94a3b8;
  margin-left: auto;
}

.pw-topbar-quit {
  padding: 0.25rem 0.625rem;
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.25);
  border-radius: 0.375rem;
  color: #f87171;
  font-size: 0.6875rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.pw-topbar-quit:hover {
  background: rgba(239, 68, 68, 0.2);
  border-color: rgba(239, 68, 68, 0.4);
}

/* ── Szenario-Karte ── */
.pw-scenario {
  background: linear-gradient(135deg, rgba(74, 222, 128, 0.1) 0%, rgba(34, 197, 94, 0.05) 100%);
  border: 1px solid rgba(74, 222, 128, 0.25);
  border-left: 4px solid #4ade80;
  border-radius: 0.75rem;
  padding: 1rem 1.125rem;
  margin-bottom: 0.75rem;
  box-shadow: 0 0 16px rgba(74, 222, 128, 0.06);
}

.pw-scenario-header {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  margin-bottom: 0.625rem;
}

.pw-scenario-emoji {
  font-size: 1.75rem;
}

.pw-scenario-title {
  font-size: 1.125rem;
  font-weight: 800;
  color: #ffffff;
  margin: 0;
  text-shadow: 0 0 10px rgba(74, 222, 128, 0.3);
}

.pw-scenario-desc {
  font-size: 0.9375rem;
  color: #e2e8f0;
  line-height: 1.6;
  margin: 0;
  font-weight: 500;
}

/* ── SVG-Dreieck ── */
.pw-triangle-container {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 0.5rem;
  margin-bottom: 0.75rem;
  background: rgba(0, 0, 0, 0.15);
  border-radius: 0.75rem;
}

.pw-triangle-svg {
  width: 100%;
  max-width: 260px;
  height: auto;
}

/* ── Frage-Bereich ── */
.pw-question {
  background: linear-gradient(135deg, rgba(74, 222, 128, 0.12) 0%, rgba(34, 197, 94, 0.06) 100%);
  border: 1px solid rgba(74, 222, 128, 0.3);
  border-left: 4px solid #4ade80;
  border-radius: 0.75rem;
  padding: 1rem 1.125rem;
  box-shadow: 0 0 20px rgba(74, 222, 128, 0.08);
}

.pw-question-title {
  font-size: 1.125rem;
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 0.5rem;
  line-height: 1.4;
  text-shadow: 0 0 12px rgba(74, 222, 128, 0.4);
}

.pw-question-hint {
  font-size: 0.8125rem;
  color: #94a3b8;
  line-height: 1.5;
  margin-bottom: 0.75rem;
}

/* ── Kombinierte Box (Beschreibung + Frage/Aufgabe) ── */
.pw-scenario-combined {
  padding: 1.125rem 1.25rem 1.25rem;
  /* Basis-Border von .pw-scenario überschreiben: kein Rahmen,
     kein dicker linker Rand – nur Trennlinien im Inneren. */
  border: none !important;
  border-left: none !important;
  background: transparent !important;
  box-shadow: none !important;
}

.pw-scenario-divider {
  border: none;
  border-top: 1px solid rgba(74, 222, 128, 0.22);
  margin: 0.875rem 0;
  opacity: 0.85;
}

/* Inline-Frage innerhalb der kombinierten Box:
   kein eigener Rahmen/Background, da schon von .pw-scenario-combined umschlossen */
.pw-question-inline {
  background: transparent !important;
  border: none !important;
  border-left: none !important;
  box-shadow: none !important;
  padding: 0 !important;
  margin: 0;
}

.pw-question-inline .pw-question-title {
  margin-top: 0;
}

/* Auflösung & Lösung inline in der kombinierten Box */
.pw-scenario-combined .pw-resolution,
.pw-scenario-combined .pw-solution {
  background: transparent !important;
  border: none !important;
  box-shadow: none !important;
  padding: 0 !important;
}

/* Feedback-Banner in der kombinierten Box */
.pw-scenario-combined .pw-step-feedback {
  margin-top: 0.5rem;
  margin-bottom: 0.75rem;
}

/* Schiebe-Labor: Regler & Formel & Aufgabe in der kombinierten Box */
.pw-scenario-combined .kl-regler-row,
.pw-scenario-combined .kl-formel-display,
.pw-scenario-combined .kl-task-area {
  margin-top: 0.75rem;
}

/* Universeller Override: ALLE inneren Boxen in der kombinierten Box
   verlieren Background/Border/Radius, außer Buttons & Reglern.
   Nur Trennlinien + Abstände strukturieren den Inhalt. */
.pw-scenario-combined > *:not(.pw-scenario-header):not(.pw-scenario-divider),
.pw-scenario-combined .pw-resolution,
.pw-scenario-combined .pw-resolution-correct,
.pw-scenario-combined .pw-resolution-wrong,
.pw-scenario-combined .pw-resolution-comparison,
.pw-scenario-combined .pw-solution,
.pw-scenario-combined .pw-solution-step,
.pw-scenario-combined .pw-solution-step-highlight,
.pw-scenario-combined .pw-solution-result,
.pw-scenario-combined .pw-solution-formel,
.pw-scenario-combined .pw-solution-steps,
.pw-scenario-combined .pw-step-feedback,
.pw-scenario-combined .pw-step-feedback-correct,
.pw-scenario-combined .pw-step-feedback-wrong,
.pw-scenario-combined .pw-question,
.pw-scenario-combined .pw-question-inline,
.pw-scenario-combined .kl-formel-display,
.pw-scenario-combined .kl-task,
.pw-scenario-combined .kl-task-area,
.pw-scenario-combined .kl-task-status,
.pw-scenario-combined .kl-predict-feedback,
.pw-scenario-combined .kl-predict-explanation,
.pw-scenario-combined .kl-predict-wrong .kl-predict-explanation,
.pw-scenario-combined .kl-explore-area,
.pw-scenario-combined .kl-explore-explanation {
  background: transparent !important;
  border: none !important;
  border-radius: 0 !important;
  box-shadow: none !important;
}

/* Innere Boxen in der kombinierten Box: KEINE Rahmen/Background,
   nur noch Trennlinien + Abstände zur Strukturierung. */
.pw-scenario-combined .pw-resolution {
  margin-top: 0.5rem;
  padding: 0.5rem 0 0;
  border-top: 1px solid rgba(74, 222, 128, 0.18) !important;
}

.pw-scenario-combined .pw-resolution-correct,
.pw-scenario-combined .pw-resolution-wrong {
  background: transparent !important;
  border: none !important;
}

.pw-scenario-combined .pw-resolution-comparison {
  background: transparent;
  border: none;
  padding: 0.375rem 0;
}

.pw-scenario-combined .pw-solution {
  padding: 0;
  background: transparent !important;
  border: none !important;
}

.pw-scenario-combined .pw-solution-step {
  background: transparent !important;
  border: none !important;
  border-bottom: 1px solid rgba(74, 222, 128, 0.1) !important;
  border-radius: 0 !important;
  padding: 0.375rem 0;
}

.pw-scenario-combined .pw-solution-step:last-child {
  border-bottom: none !important;
}

.pw-scenario-combined .pw-solution-step-highlight {
  background: transparent !important;
  border: none !important;
  border-bottom: 1px solid rgba(74, 222, 128, 0.25) !important;
}

.pw-scenario-combined .pw-solution-result {
  background: transparent !important;
  border: none !important;
  border-top: 1px solid rgba(74, 222, 128, 0.18) !important;
  border-radius: 0 !important;
  padding: 0.5rem 0 0;
  margin-top: 0.375rem;
}

.pw-scenario-combined .pw-step-feedback-correct,
.pw-scenario-combined .pw-step-feedback-wrong {
  background: transparent !important;
  border: none !important;
  border-top: 1px solid rgba(74, 222, 128, 0.18) !important;
  border-radius: 0 !important;
  padding: 0.375rem 0;
}

/* Schiebe-Labor: Formel-Anzeige & Aufgaben-Box ohne Rahmen/Hintergrund */
.pw-scenario-combined .kl-formel-display {
  background: transparent !important;
  border: none !important;
  border-top: 1px solid rgba(74, 222, 128, 0.18) !important;
  border-radius: 0 !important;
  padding: 0.5rem 0 0 !important;
}

.pw-scenario-combined .kl-task {
  background: transparent !important;
  border: none !important;
  border-top: 1px solid rgba(251, 191, 36, 0.22) !important;
  border-radius: 0 !important;
  padding: 0.5rem 0 0 !important;
}

.pw-scenario-combined .kl-task-title {
  margin-top: 0;
}

.pw-scenario-combined .kl-predict-feedback {
  background: transparent !important;
  border: none !important;
  border-top: 1px solid rgba(74, 222, 128, 0.18) !important;
  border-radius: 0 !important;
  padding: 0.375rem 0 0 !important;
  margin-top: 0.375rem;
}

.pw-scenario-combined .kl-explore-area {
  border: none;
}

/* Vorhersage-Erklärung & Explore-Erklärung: kein eigener Hintergrund */
.pw-scenario-combined .kl-predict-explanation,
.pw-scenario-combined .kl-predict-wrong .kl-predict-explanation,
.pw-scenario-combined .kl-explore-explanation {
  background: transparent !important;
  border: none !important;
  border-radius: 0 !important;
  padding: 0.25rem 0 !important;
}

/* kl-task-status ohne extra Box-Charakter */
.pw-scenario-combined .kl-task-status {
  margin-top: 0.375rem;
}

/* ── Antwort-Optionen ── */
.pw-options {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.pw-options-formula {
  gap: 0.625rem;
}

.pw-option-btn {
  padding: 0.625rem 0.875rem;
  background: rgba(74, 222, 128, 0.06);
  border: 1px solid rgba(74, 222, 128, 0.15);
  border-radius: 0.5rem;
  color: #e2e8f0;
  font-size: 0.8125rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: center;
}

.pw-option-btn:hover:not(:disabled) {
  background: rgba(74, 222, 128, 0.12);
  border-color: rgba(74, 222, 128, 0.3);
  transform: translateY(-1px);
}

.pw-option-btn:active:not(:disabled) {
  transform: translateY(0);
}

.pw-option-btn:disabled {
  cursor: default;
  opacity: 0.7;
}

/* Formel-Buttons größer */
.pw-formula-btn {
  font-size: 0.9375rem;
  font-family: 'Inter', sans-serif;
  padding: 0.75rem 1rem;
}

/* Korrekt / Falsch */
.pw-option-correct {
  background: rgba(74, 222, 128, 0.2) !important;
  border-color: #4ade80 !important;
  color: #4ade80 !important;
  font-weight: 700;
  animation: pw-correct-flash 0.4s ease;
}

@keyframes pw-correct-flash {
  0% { box-shadow: 0 0 0 0 rgba(74, 222, 128, 0.5); }
  100% { box-shadow: 0 0 0 8px rgba(74, 222, 128, 0); }
}

.pw-option-wrong {
  background: rgba(239, 68, 68, 0.15) !important;
  border-color: #ef4444 !important;
  color: #f87171 !important;
  animation: pw-wrong-shake 0.4s ease;
}

@keyframes pw-wrong-shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-4px); }
  75% { transform: translateX(4px); }
}

/* ── Feedback-Banner ── */
.pw-feedback {
  margin-top: 0.75rem;
  padding: 0.625rem 0.875rem;
  border-radius: 0.5rem;
  font-size: 0.8125rem;
  line-height: 1.5;
  animation: pw-feedback-slide 0.3s ease;
}

@keyframes pw-feedback-slide {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

.pw-feedback-correct {
  background: rgba(74, 222, 128, 0.1);
  border: 1px solid rgba(74, 222, 128, 0.25);
  color: #4ade80;
}

.pw-feedback-wrong {
  background: rgba(239, 68, 68, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.2);
  color: #f87171;
}

/* ── Auflösungs-Schritt (eigener Schritt) ── */
.pw-resolution {
  margin-top: 1rem;
  padding: 1.25rem 1.5rem;
  border-radius: 0.75rem;
  text-align: center;
  animation: pw-feedback-slide 0.3s ease;
}

.pw-resolution-correct {
  background: rgba(74, 222, 128, 0.1);
  border: 1px solid rgba(74, 222, 128, 0.3);
}

.pw-resolution-wrong {
  background: rgba(239, 68, 68, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.25);
}

.pw-resolution-icon {
  font-size: 2rem;
  margin: 0 0 0.5rem;
}

.pw-resolution-text {
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.5;
  margin: 0 0 0.875rem;
}

.pw-resolution-correct .pw-resolution-text {
  color: #4ade80;
}

.pw-resolution-wrong .pw-resolution-text {
  color: #f87171;
}

.pw-resolution-comparison {
  margin-bottom: 1rem;
  padding: 0.75rem;
  background: rgba(0, 0, 0, 0.2);
  border-radius: 0.5rem;
  text-align: left;
}

.pw-resolution-comparison-line {
  font-size: 0.8125rem;
  margin: 0.25rem 0;
  display: flex;
  gap: 0.5rem;
  align-items: baseline;
}

.pw-resolution-label {
  color: #64748b;
  font-weight: 600;
  min-width: 7rem;
  flex-shrink: 0;
}

.pw-resolution-selected {
  color: #f87171;
  font-weight: 700;
}

.pw-resolution-answer {
  color: #4ade80;
  font-weight: 700;
}

.pw-resolution-btn {
  display: inline-block;
  padding: 0.625rem 1.5rem;
  font-size: 0.875rem;
}

/* ── Schritt-Feedback (klein, aus vorherigem Schritt) ── */
.pw-step-feedback {
  padding: 0.5rem 0.75rem;
  border-radius: 0.5rem;
  font-size: 0.75rem;
  margin-bottom: 0.75rem;
  text-align: center;
}

.pw-step-feedback-correct {
  background: rgba(74, 222, 128, 0.08);
  color: #4ade80;
}

.pw-step-feedback-wrong {
  background: rgba(245, 158, 11, 0.08);
  color: #fbbf24;
}

/* ── Animierter Lösungsweg ── */
.pw-solution {
  background: rgba(74, 222, 128, 0.04);
  border: 1px solid rgba(74, 222, 128, 0.1);
  border-radius: 0.75rem;
  padding: 1rem;
  text-align: center;
}

.pw-solution-title {
  font-size: 0.9375rem;
  font-weight: 700;
  color: #4ade80;
  margin-bottom: 0.5rem;
}

.pw-solution-formel {
  font-size: 0.8125rem;
  color: #cbd5e1;
  margin-bottom: 0.75rem;
}

.pw-solution-steps {
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
  margin-bottom: 0.75rem;
}

.pw-solution-step {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.75rem;
  background: rgba(74, 222, 128, 0.05);
  border: 1px solid rgba(74, 222, 128, 0.1);
  border-radius: 0.5rem;
  opacity: 0;
  animation: pw-step-appear 0.4s ease forwards;
}

@keyframes pw-step-appear {
  from { opacity: 0; transform: translateX(-12px); }
  to { opacity: 1; transform: translateX(0); }
}

.pw-solution-step-label {
  flex-shrink: 0;
  font-size: 0.6875rem;
  color: #94a3b8;
  font-weight: 600;
  min-width: 5.5rem;
  text-align: left;
}

.pw-solution-step-rechnung {
  font-size: 0.8125rem;
  color: #e2e8f0;
  font-family: 'Inter', sans-serif;
  text-align: left;
}

.pw-solution-step-highlight {
  background: rgba(74, 222, 128, 0.15);
  border-color: #4ade80;
}

.pw-solution-step-highlight .pw-solution-step-rechnung {
  color: #4ade80;
  font-weight: 700;
  font-size: 0.9375rem;
}

.pw-solution-result {
  font-size: 1rem;
  font-weight: 700;
  color: #4ade80;
  padding: 0.625rem;
  background: rgba(74, 222, 128, 0.08);
  border-radius: 0.5rem;
  margin-bottom: 0.75rem;
  animation: pw-result-pop 0.5s ease 1.4s both;
}

@keyframes pw-result-pop {
  0% { opacity: 0; transform: scale(0.8); }
  50% { transform: scale(1.05); }
  100% { opacity: 1; transform: scale(1); }
}

/* ── Weiter-Button ── */
.pw-btn-next {
  background: linear-gradient(135deg, #22c55e, #16a34a) !important;
  width: 100%;
}
.pw-btn-next:hover {
  background: linear-gradient(135deg, #4ade80, #22c55e) !important;
  transform: scale(1.02);
}

/* ── Ergebnis (Overrides für grünes Farbschema) ── */
.pw-result {
  background: rgba(74, 222, 128, 0.05);
}

/* ── Responsive ── */
@media (max-width: 480px) {
  .pw-topbar {
    font-size: 0.6875rem;
    gap: 0.375rem;
  }
  .pw-topbar-timer {
    margin-left: 0;
  }
  .pw-scenario-title {
    font-size: 0.875rem;
  }
  .pw-scenario-desc {
    font-size: 0.75rem;
  }
  .pw-question-title {
    font-size: 0.8125rem;
  }
  .pw-option-btn {
    font-size: 0.75rem;
    padding: 0.5rem 0.625rem;
  }
  .pw-formula-btn {
    font-size: 0.8125rem;
    padding: 0.625rem 0.75rem;
  }
  .pw-solution-step {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.25rem;
  }
  .pw-solution-step-label {
    min-width: 0;
  }
  .pw-scenario-combined {
    padding: 0.875rem 0.875rem 1rem;
  }
  .pw-scenario-divider {
    margin: 0.625rem 0;
  }
}

/* ═══════════════════════════════════════════════════════════
   KRAFT-WERKSTATT + SCHIEBE-LABOR (kw-* / kl-* Klassen)
   ═══════════════════════════════════════════════════════════ */

/* ── Modal-Content Override (grünes Farbschema, analog pw-) ── */
.kw-modal-content {
  background: linear-gradient(160deg, #0f1f15 0%, #0a1410 100%);
}
.kw-modal-content::-webkit-scrollbar-thumb {
  background: rgba(74, 222, 128, 0.2);
}
.kw-modal-content::-webkit-scrollbar-thumb:hover {
  background: rgba(74, 222, 128, 0.35);
}

/* ── Intro-Hinweis (Vereinfachung) ── */
.kw-intro-hint {
  background: rgba(251, 191, 36, 0.08);
  border: 1px solid rgba(251, 191, 36, 0.2);
  border-radius: 0.625rem;
  padding: 0.75rem 1rem;
  margin-bottom: 1rem;
}

.kw-intro-hint p {
  font-size: 0.8125rem;
  color: #cbd5e1;
  line-height: 1.5;
  margin: 0;
}

/* ── Szenario-Visualisierung (Emoji + Pfeil + Badges) ── */
.kw-scenario-visual {
  padding: 0.5rem 1rem 1rem;
  margin-bottom: 1rem;
  text-align: center;
}

.kw-visual-stage {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
  min-height: 60px;
}

/* Vertikale Anordnung für nach-oben-Kräfte (z. B. Gewichtheber) */
.kw-visual-stage-up {
  flex-direction: column;
  gap: 0.25rem;
}

/* Pfeil vor dem Emoji für nach-links-gerichtete Objekte (z. B. Auto, Einkaufswagen) */
.kw-visual-stage-left {
  flex-direction: row-reverse;
}

.kw-visual-emoji {
  font-size: 2.5rem;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.2em;
  min-height: 1em;
}

.kw-visual-arrow {
  font-size: 1.5rem;
  color: #4ade80;
  font-weight: 800;
}

.kw-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
}

.kw-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.375rem 0.75rem;
  border-radius: 0.5rem;
  font-size: 0.8125rem;
  font-weight: 700;
  font-family: 'Inter', sans-serif;
}

.kw-badge-given {
  background: rgba(74, 222, 128, 0.15);
  border: 1px solid rgba(74, 222, 128, 0.3);
  color: #4ade80;
}

.kw-badge-sought {
  background: rgba(251, 191, 36, 0.15);
  border: 1px solid rgba(251, 191, 36, 0.4);
  color: #fbbf24;
}

/* ── Schiebe-Labor ── */
.kl-lab-visual {
  padding: 0.5rem 1rem 1.25rem;
  margin-bottom: 1rem;
  text-align: center;
}

.kl-block-track {
  position: relative;
  height: 60px;
  margin-bottom: 0.75rem;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.kl-block {
  font-size: 2rem;
  line-height: 1;
  position: absolute;
  left: 10px;
  animation: kl-block-move 2s ease-in-out infinite alternate;
  transition: opacity 0.3s ease;
}

@keyframes kl-block-move {
  from { transform: translateX(0); }
  to   { transform: translateX(140px); }
}

.kl-kraft-pfeil {
  position: absolute;
  left: 50px;
  height: 6px;
  background: linear-gradient(90deg, #4ade80 0%, #22c55e 100%);
  border-radius: 3px;
  transition: width 0.2s ease, opacity 0.3s ease;
  box-shadow: 0 0 8px rgba(74, 222, 128, 0.4);
}

.kl-kraft-pfeil::after {
  content: '';
  position: absolute;
  right: -8px;
  top: 50%;
  transform: translateY(-50%);
  border-left: 10px solid #22c55e;
  border-top: 7px solid transparent;
  border-bottom: 7px solid transparent;
}

.kl-kraft-display {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.kl-kraft-label {
  font-size: 0.9375rem;
  color: #94a3b8;
  font-weight: 600;
}

.kl-kraft-wert {
  font-size: 1.75rem;
  font-weight: 800;
  color: #4ade80;
  font-family: 'Inter', sans-serif;
  text-shadow: 0 0 12px rgba(74, 222, 128, 0.3);
  transition: color 0.3s ease, text-shadow 0.3s ease;
}

.kl-kraft-wert-zero {
  color: #64748b;
  text-shadow: none;
}

/* ── Schieberegler ── */
.kl-regler-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  margin-bottom: 1rem;
  padding: 0 1rem;
}

.kl-regler-group {
  padding: 0.75rem 1rem;
}

.kl-regler-label {
  display: block;
  font-size: 0.8125rem;
  color: #cbd5e1;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.kl-regler-label span {
  color: #60a5fa;
  font-weight: 800;
}

.kl-regler {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 6px;
  border-radius: 3px;
  background: rgba(96, 165, 250, 0.2);
  outline: none;
  cursor: pointer;
}

.kl-regler::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: linear-gradient(135deg, #60a5fa, #3b82f6);
  cursor: pointer;
  box-shadow: 0 0 8px rgba(96, 165, 250, 0.5);
  border: 2px solid #1e293b;
}

.kl-regler::-moz-range-thumb {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: linear-gradient(135deg, #60a5fa, #3b82f6);
  cursor: pointer;
  box-shadow: 0 0 8px rgba(96, 165, 250, 0.5);
  border: 2px solid #1e293b;
}

/* ── Formel-Anzeige im Labor ── */
.kl-formel-display {
  background: rgba(74, 222, 128, 0.06);
  border: 1px solid rgba(74, 222, 128, 0.15);
  border-radius: 0.5rem;
  padding: 0.625rem 0.75rem;
  margin-bottom: 1rem;
  text-align: center;
  font-size: 0.9375rem;
}

/* ── Aufgaben-Bereich ── */
.kl-task {
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.08) 0%, rgba(74, 222, 128, 0.04) 100%);
  border: 1px solid rgba(251, 191, 36, 0.2);
  border-radius: 0.75rem;
  padding: 1rem;
}

.kl-task-title {
  font-size: 0.875rem;
  font-weight: 700;
  color: #fbbf24;
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.kl-task-desc {
  font-size: 0.9375rem;
  color: #e2e8f0;
  line-height: 1.5;
  margin-bottom: 0.75rem;
}

.kl-task-status {
  margin-top: 0.5rem;
}

.kl-task-success {
  display: block;
  color: #4ade80;
  font-weight: 700;
  font-size: 0.9375rem;
  margin-bottom: 0.75rem;
}

.kl-task-hint {
  display: block;
  color: #94a3b8;
  font-size: 0.8125rem;
  margin-bottom: 0.5rem;
}

.kl-task-tip {
  font-size: 0.75rem;
  color: #64748b;
  font-style: italic;
}

/* ── Vorhersage-Optionen ── */
.kl-predict-options {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.kl-predict-btn {
  text-align: left;
}

.kl-predict-feedback {
  margin-top: 0.5rem;
}

.kl-predict-result {
  font-size: 1rem;
  font-weight: 800;
  margin-bottom: 0.5rem;
}

.kl-predict-correct .kl-predict-result {
  color: #4ade80;
}

.kl-predict-wrong .kl-predict-result {
  color: #f87171;
}

.kl-predict-explanation {
  font-size: 0.875rem;
  color: #cbd5e1;
  line-height: 1.5;
  margin-bottom: 0.75rem;
  background: rgba(74, 222, 128, 0.08);
  padding: 0.625rem 0.75rem;
  border-radius: 0.5rem;
}

.kl-predict-wrong .kl-predict-explanation {
  background: rgba(239, 68, 68, 0.08);
}

/* ── Explore-Bereich ── */
.kl-explore-area {
  margin-top: 0.5rem;
}

.kl-explore-hint {
  font-size: 0.875rem;
  color: #94a3b8;
  margin-bottom: 0.75rem;
}

.kl-explore-explanation {
  font-size: 0.875rem;
  color: #4ade80;
  line-height: 1.5;
  margin-bottom: 0.75rem;
  background: rgba(74, 222, 128, 0.08);
  padding: 0.625rem 0.75rem;
  border-radius: 0.5rem;
}

.kl-explore-confirm {
  background: rgba(96, 165, 250, 0.15) !important;
  border: 1px solid rgba(96, 165, 250, 0.3) !important;
}

.kl-explore-confirm:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* ── Responsive ── */
@media (max-width: 480px) {
  .kl-regler-row {
    grid-template-columns: 1fr;
    gap: 0.625rem;
  }
  .kw-visual-emoji {
    font-size: 2rem;
  }
  .kl-kraft-wert {
    font-size: 1.375rem;
  }
  .kl-block {
    font-size: 1.5rem;
  }
  @keyframes kl-block-move {
    from { transform: translateX(0); }
    to   { transform: translateX(100px); }
  }
}

/* ═══════════════════════════════════════════════════════════
   FIBONACCI-THEMA – Visual, Formel-Box, Folgen-Kacheln, Goldener-Schnitt
   ═══════════════════════════════════════════════════════════ */

/* ── Fibonacci-Spirale (SVG-Visual) ── */
.fibonacci-visual {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(ellipse at center, #0a1a0e 0%, #060f08 100%);
  overflow: hidden;
}

.fibonacci-svg {
  width: 260px;
  height: 260px;
  max-width: 90%;
  height: auto;
  filter: drop-shadow(0 0 12px rgba(34, 197, 94, 0.25));
  animation: fibonacci-svg-pulse 4s ease-in-out infinite;
}

@keyframes fibonacci-svg-pulse {
  0%, 100% { filter: drop-shadow(0 0 12px rgba(34, 197, 94, 0.25)); }
  50% { filter: drop-shadow(0 0 18px rgba(34, 197, 94, 0.4)); }
}

@media (max-width: 768px) {
  .fibonacci-svg {
    width: 210px;
  }
}

@media (max-width: 480px) {
  .fibonacci-svg {
    width: 170px;
  }
}

/* ── Fibonacci-Formel-Box ── */
.fibonacci-box {
  background: rgba(34, 197, 94, 0.05);
  border: 1px solid rgba(34, 197, 94, 0.12);
  border-radius: 1rem;
  padding: 1.25rem 1.5rem;
  margin-bottom: 1.5rem;
}

.fibonacci-intro {
  font-weight: 700;
  font-size: 0.875rem;
  color: #86efac;
  margin-bottom: 1rem;
}

.fibonacci-formula {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  font-size: 1.75rem;
  font-weight: 800;
  margin-bottom: 1.25rem;
}

.fibonacci-term {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  background: rgba(34, 197, 94, 0.08);
  border: 1px solid rgba(34, 197, 94, 0.15);
  border-radius: 0.75rem;
  padding: 0.5rem 0.875rem;
  transition: all 0.2s ease;
}

.fibonacci-term:hover {
  background: rgba(34, 197, 94, 0.15);
  border-color: rgba(34, 197, 94, 0.3);
  transform: translateY(-2px);
}

.fibonacci-term-letter {
  color: #22c55e;
  font-weight: 800;
  font-size: 1.25rem;
}

.fibonacci-op {
  color: #86efac;
  font-size: 1.5rem;
  font-weight: 700;
}

/* ── Fibonacci-Formel-Legende ── */
.fibonacci-formula-legend-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 1rem;
}

.fibonacci-formula-legend-item {
  display: flex;
  align-items: flex-start;
  gap: 0.875rem;
  background: rgba(34, 197, 94, 0.06);
  border: 1px solid rgba(34, 197, 94, 0.12);
  border-radius: 0.75rem;
  padding: 0.75rem 1rem;
  transition: all 0.2s ease;
}

.fibonacci-formula-legend-item:hover {
  background: rgba(34, 197, 94, 0.1);
  border-color: rgba(34, 197, 94, 0.25);
}

.fibonacci-formula-legend-letter {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 3.5rem;
  height: 2.25rem;
  flex-shrink: 0;
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.25);
  border-radius: 0.5rem;
  font-size: 1rem;
  font-weight: 800;
  color: #22c55e;
  text-shadow: 0 0 8px rgba(34, 197, 94, 0.4);
  padding: 0 0.5rem;
}

.fibonacci-formula-legend-text {
  font-size: 0.9375rem;
  color: #cbd5e1;
  line-height: 1.5;
  align-self: center;
}

.fibonacci-formula-legend-text b {
  color: #86efac;
  font-weight: 700;
}

@media (max-width: 480px) {
  .fibonacci-formula-legend-item {
    flex-direction: column;
    gap: 0.5rem;
  }

  .fibonacci-formula-legend-text {
    align-self: stretch;
  }
}

/* ── Folgen-Kacheln ── */
.fibonacci-sequence {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
  align-items: center;
  margin: 1rem 0;
}

.fibonacci-tile {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 3rem;
  height: 3rem;
  padding: 0 0.5rem;
  background: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.25);
  border-radius: 0.6rem;
  font-size: 1.25rem;
  font-weight: 800;
  color: #4ade80;
  font-variant-numeric: tabular-nums;
  transition: all 0.2s ease;
}

.fibonacci-tile:hover {
  background: rgba(34, 197, 94, 0.18);
  border-color: rgba(34, 197, 94, 0.4);
  transform: translateY(-2px);
}

.fibonacci-arrow {
  display: inline-flex;
  align-items: center;
  color: rgba(74, 222, 128, 0.5);
  font-size: 1.25rem;
  font-weight: 700;
}

@media (max-width: 480px) {
  .fibonacci-tile {
    min-width: 2.25rem;
    height: 2.25rem;
    font-size: 0.9375rem;
  }

  .fibonacci-arrow {
    font-size: 0.875rem;
  }
}

/* ── Goldener-Schnitt-Box ── */
.fibonacci-ratio-rows {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin: 0.5rem 0;
}

.fibonacci-ratio-row {
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(34, 197, 94, 0.06);
  border: 1px solid rgba(34, 197, 94, 0.12);
  border-radius: 0.5rem;
  padding: 0.4rem 0.75rem;
  font-size: 0.9375rem;
  color: #cbd5e1;
  font-variant-numeric: tabular-nums;
  transition: all 0.2s ease;
}

.fibonacci-ratio-row:hover {
  background: rgba(34, 197, 94, 0.1);
  border-color: rgba(34, 197, 94, 0.25);
}

.fibonacci-ratio-converge {
  background: rgba(251, 191, 36, 0.1);
  border-color: rgba(251, 191, 36, 0.35);
  font-weight: 800;
  color: #fbbf24;
  font-size: 1.0625rem;
  box-shadow: 0 0 12px rgba(251, 191, 36, 0.15);
}

.fibonacci-ratio-converge:hover {
  background: rgba(251, 191, 36, 0.15);
  border-color: rgba(251, 191, 36, 0.5);
}

/* ═══════════════════════════════════════════════════════════
   FIBONACCI-WERKSTATT – Minispiel-Styles (fw-*)
   ═══════════════════════════════════════════════════════════ */

/* ── Folgen-Kacheln im Werkstatt-Modal ── */
.fw-sequence {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
  align-items: center;
  margin: 1.25rem 0;
}

.fw-tile {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 3rem;
  height: 3rem;
  padding: 0 0.5rem;
  background: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.25);
  border-radius: 0.6rem;
  font-size: 1.25rem;
  font-weight: 800;
  color: #4ade80;
  font-variant-numeric: tabular-nums;
  transition: all 0.3s ease;
}

.fw-tile-unknown {
  background: rgba(251, 191, 36, 0.1);
  border-color: rgba(251, 191, 36, 0.4);
  color: #fbbf24;
  animation: fw-tile-pulse 1.5s ease-in-out infinite;
}

@keyframes fw-tile-pulse {
  0%, 100% { box-shadow: 0 0 8px rgba(251, 191, 36, 0.2); }
  50% { box-shadow: 0 0 16px rgba(251, 191, 36, 0.4); }
}

.fw-tile-solved {
  background: rgba(34, 197, 94, 0.2);
  border-color: rgba(34, 197, 94, 0.5);
  color: #22c55e;
  box-shadow: 0 0 12px rgba(34, 197, 94, 0.3);
}

.fw-arrow {
  display: inline-flex;
  align-items: center;
  color: rgba(74, 222, 128, 0.5);
  font-size: 1.25rem;
  font-weight: 700;
}

@media (max-width: 480px) {
  .fw-tile {
    min-width: 2.25rem;
    height: 2.25rem;
    font-size: 0.9375rem;
  }

  .fw-arrow {
    font-size: 0.875rem;
  }
}

/* ── Spiel-Container: Padding für Fibonacci-Werkstatt ── */
.fw-modal-content .pw-playing {
  padding: 1.25rem 1.5rem 1.5rem;
}

/* ── Szenario-Visual (Emoji + Beschreibung) ── */
.fw-scenario-visual {
  text-align: center;
  margin-bottom: 1rem;
}

.fw-scenario-emoji {
  font-size: 3rem;
  line-height: 1;
  margin-bottom: 0.5rem;
}

.fw-scenario-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: #86efac;
  margin-bottom: 0.5rem;
}

.fw-scenario-desc {
  font-size: 0.9375rem;
  color: #cbd5e1;
  line-height: 1.5;
}

/* ── Antwort-Buttons (Zahlen / Regeln) ── */
.fw-answer-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: center;
  margin: 1rem 0;
}

.fw-answer-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 5rem;
  padding: 0.875rem 1.5rem;
  background: rgba(34, 197, 94, 0.08);
  border: 2px solid rgba(34, 197, 94, 0.25);
  border-radius: 0.875rem;
  color: #4ade80;
  font-size: 1.25rem;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.2s ease;
  font-variant-numeric: tabular-nums;
}

.fw-answer-btn:hover {
  background: rgba(34, 197, 94, 0.15);
  border-color: rgba(34, 197, 94, 0.45);
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(34, 197, 94, 0.15);
}

.fw-answer-btn:active {
  transform: translateY(0) scale(0.97);
}

.fw-answer-btn.fw-correct {
  background: rgba(34, 197, 94, 0.25);
  border-color: #22c55e;
  color: #22c55e;
  box-shadow: 0 0 20px rgba(34, 197, 94, 0.4);
}

.fw-answer-btn.fw-wrong {
  background: rgba(239, 68, 68, 0.15);
  border-color: rgba(239, 68, 68, 0.5);
  color: #fca5a5;
  animation: fw-shake 0.4s ease;
}

@keyframes fw-shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-6px); }
  75% { transform: translateX(6px); }
}

.fw-answer-btn:disabled {
  cursor: default;
  opacity: 0.6;
}

/* ── Feedback-Banner ── */
.fw-feedback {
  text-align: center;
  padding: 0.75rem 1rem;
  border-radius: 0.75rem;
  margin: 0.75rem 0;
  font-weight: 700;
  font-size: 0.9375rem;
  animation: fw-fade-in 0.3s ease;
}

.fw-feedback-correct {
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.3);
  color: #86efac;
}

.fw-feedback-wrong {
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.25);
  color: #fca5a5;
}

@keyframes fw-fade-in {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ── Combo-Anzeige ── */
.fw-combo {
  text-align: center;
  font-size: 0.875rem;
  font-weight: 700;
  color: #fbbf24;
  margin: 0.5rem 0;
  min-height: 1.25rem;
}

.fw-combo-active {
  animation: fw-combo-pop 0.4s ease;
}

@keyframes fw-combo-pop {
  0% { transform: scale(0.8); opacity: 0; }
  50% { transform: scale(1.2); }
  100% { transform: scale(1); opacity: 1; }
}

/* ── Animierter Lösungsweg ── */
.fw-solution {
  margin: 1rem 0;
}

.fw-solution-title {
  font-size: 0.9375rem;
  font-weight: 700;
  color: #86efac;
  margin-bottom: 0.75rem;
  text-align: center;
}

.fw-solution-steps {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.fw-solution-step {
  display: flex;
  align-items: baseline;
  gap: 0.6rem;
  background: rgba(34, 197, 94, 0.06);
  border-left: 3px solid rgba(34, 197, 94, 0.35);
  border-radius: 0.4rem;
  padding: 0.5rem 0.7rem;
  opacity: 0;
  animation: fw-step-fade 0.4s ease forwards;
}

@keyframes fw-step-fade {
  from { opacity: 0; transform: translateX(-8px); }
  to { opacity: 1; transform: translateX(0); }
}

.fw-solution-step-label {
  font-size: 0.75rem;
  font-weight: 700;
  color: #86efac;
  white-space: nowrap;
  flex-shrink: 0;
  min-width: 5rem;
}

.fw-solution-step-rechnung {
  font-size: 0.9375rem;
  color: #e2e8f0;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  line-height: 1.4;
}

.fw-solution-step-highlight {
  background: rgba(34, 197, 94, 0.14);
  border-left-color: #22c55e;
  box-shadow: 0 0 12px rgba(34, 197, 94, 0.15);
}

.fw-solution-step-highlight .fw-solution-step-rechnung {
  color: #bbf7d0;
  font-weight: 800;
}

.fw-solution-result {
  text-align: center;
  font-size: 1.0625rem;
  font-weight: 800;
  color: #22c55e;
  margin-top: 0.75rem;
  padding: 0.5rem 0.75rem;
  background: rgba(34, 197, 94, 0.1);
  border-radius: 0.6rem;
}

/* ── Weiter-Button ── */
.fw-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.75rem;
  border-radius: 0.75rem;
  font-weight: 700;
  font-size: 0.9375rem;
  cursor: pointer;
  transition: all 0.2s ease;
  border: none;
  margin: 0.75rem auto 0;
}

.fw-btn-next {
  background: linear-gradient(135deg, #22c55e, #16a34a);
  color: white;
  box-shadow: 0 0 15px rgba(34, 197, 94, 0.3);
}

.fw-btn-next:hover {
  transform: scale(1.05);
  box-shadow: 0 0 25px rgba(34, 197, 94, 0.5);
}

.fw-btn:active {
  transform: scale(0.97);
}

/* ── Frage-Label ── */
.fw-question-label {
  text-align: center;
  font-size: 1rem;
  font-weight: 700;
  color: #86efac;
  margin: 0.75rem 0 0.25rem;
}

/* ── Runden-Fortschritt ── */
.fw-progress {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
  font-size: 0.8125rem;
  color: #64748b;
  font-weight: 600;
}

.fw-progress-dots {
  display: flex;
  gap: 4px;
}

.fw-progress-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(34, 197, 94, 0.2);
  transition: all 0.3s ease;
}

.fw-progress-dot.active {
  background: #22c55e;
  box-shadow: 0 0 8px rgba(34, 197, 94, 0.5);
}

.fw-progress-dot.done {
  background: rgba(34, 197, 94, 0.5);
}

/* ── Ergebnis-Phase ── */
.fw-result {
  text-align: center;
  padding: 1.5rem 1rem;
}

.fw-result-stars {
  font-size: 2.5rem;
  margin-bottom: 0.75rem;
  letter-spacing: 0.25rem;
}

.fw-result-title {
  font-size: 1.5rem;
  font-weight: 800;
  color: #86efac;
  margin-bottom: 0.5rem;
}

.fw-result-score {
  font-size: 1.25rem;
  font-weight: 700;
  color: #4ade80;
  margin-bottom: 0.25rem;
}

.fw-result-combo {
  font-size: 0.875rem;
  color: #fbbf24;
  font-weight: 600;
  margin-bottom: 1rem;
}

.fw-result-xp {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: rgba(34, 197, 94, 0.12);
  border: 1px solid rgba(34, 197, 94, 0.3);
  border-radius: 0.6rem;
  padding: 0.5rem 1rem;
  font-size: 1rem;
  font-weight: 700;
  color: #22c55e;
  margin-bottom: 1.25rem;
}

.fw-result-actions {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
}

.fw-btn-restart {
  background: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.3);
  color: #4ade80;
}

.fw-btn-restart:hover {
  background: rgba(34, 197, 94, 0.2);
  border-color: rgba(34, 197, 94, 0.5);
  transform: scale(1.05);
}

.fw-btn-close {
  background: transparent;
  border: 1px solid rgba(100, 116, 139, 0.3);
  color: #94a3b8;
}

.fw-btn-close:hover {
  background: rgba(100, 116, 139, 0.1);
  border-color: rgba(100, 116, 139, 0.5);
  color: #cbd5e1;
}

/* ── Intro-Phase ── */
.fw-intro-rules {
  text-align: left;
  margin: 1rem 0;
  padding: 0.75rem 1rem;
  background: rgba(34, 197, 94, 0.05);
  border: 1px solid rgba(34, 197, 94, 0.12);
  border-radius: 0.75rem;
}

.fw-intro-rule {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  font-size: 0.875rem;
  color: #cbd5e1;
  line-height: 1.5;
  margin-bottom: 0.5rem;
}

.fw-intro-rule:last-child {
  margin-bottom: 0;
}

.fw-intro-rule-emoji {
  flex-shrink: 0;
  font-size: 1rem;
}

.fw-intro-scoring {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  justify-content: center;
  font-size: 0.75rem;
  color: #94a3b8;
  margin-bottom: 1.25rem;
}

.fw-intro-actions {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
}

@media (max-width: 480px) {
  .fw-answer-btn {
    min-width: 4rem;
    padding: 0.625rem 1rem;
    font-size: 1rem;
  }

  .fw-scenario-emoji {
    font-size: 2.5rem;
  }

  .fw-solution-step {
    flex-direction: column;
    gap: 0.2rem;
  }

  .fw-solution-step-label {
    min-width: unset;
  }

  .fw-result-stars {
    font-size: 2rem;
  }

  .fw-modal-content .pw-playing {
    padding: 1rem 1rem 1.25rem;
  }
}
