<style>
/* Haupt-Container */
.stats-wrapper {
  padding: 40px;
  border-radius: 12px;
  font-family: Arial, sans-serif;
  max-width: 900px;
  margin: 0 auto;
}

.stats-header {
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 30px;
}

/* Layout für Balken und rechte Box */
.stats-main-layout {
  display: flex;
  gap: 40px;
  align-items: flex-end;
}

/* Die Balken-Sektion */
.risk-bars {
  display: flex;
  flex: 1;
  justify-content: space-between;
  gap: 15px;
}

.risk-bar {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
  max-width: 120px;
}

.risk-bar__pct {
  font-size: 28px;
  font-weight: bold;
  margin-bottom: 15px;
}

/* Der graue Hintergrund der Balken */
.risk-bar__track {
  width: 100%;
  height: 220px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  position: relative;
  margin-bottom: 15px;
}

/* Die Füllung der Balken */
.risk-bar__fill {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  border-radius: 8px 8px 0 0;
  transition: height 1s ease-out;
}

.risk-bar__label {
  font-size: 14px;
  font-weight: 600;
  text-align: center;
}

/* Rechte Durchschnittsalter-Box (Zentriert für Desktop) */
.age-cohort-box {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 25px;
  border-radius: 12px;
  width: 220px;
  margin-bottom: 35px;
  text-align: center;
  box-sizing: border-box;
}

.age-title {
  font-size: 14px;
  font-weight: bold;
  margin-bottom: 5px;
  line-height: 1.4;
}

.age-sub {
  font-size: 12px;
  margin-bottom: 25px;
}

.age-row {
  font-size: 26px;
  font-weight: bold;
  margin-bottom: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.age-sym {
  font-weight: normal;
  font-size: 22px;
}

/* Mobile Anpassung (Smartphones) */
@media (max-width: 768px) {
  .stats-wrapper {
    padding: 20px 10px;
  }
  .stats-main-layout {
    flex-direction: column;
    align-items: center;
  }
  .risk-bars {
    width: 100%;
    gap: 5px;
  }
  .risk-bar__pct {
    font-size: 22px;
  }
  .risk-bar__label {
    font-size: 11px;
    hyphens: auto;
  }
  
  /* NEUES MOBILE LAYOUT FÜR DIE ALTERS-BOX */
  .age-cohort-box {
    width: 100%;
    margin-top: 30px;
    margin-bottom: 0;
    display: grid; /* Aktiviert das Grid-System */
    grid-template-columns: 1fr 1fr; /* Erstellt zwei gleich große Spalten */
    column-gap: 10px;
    row-gap: 5px;
    padding: 20px;
  }
  
  .age-title {
    grid-column: 1 / -1; /* Streckt die Überschrift über beide Spalten */
    margin-bottom: 0;
  }
  
  .age-title br {
    display: none; /* Entfernt den Zeilenumbruch auf Mobile */
  }
  
  .age-sub {
    grid-column: 1 / -1; /* Streckt "in Jahren" über beide Spalten */
    margin-bottom: 15px; /* Abstand zu den Werten darunter */
  }
  
  .age-row {
    grid-column: span 1; /* Setzt die beiden Werte nebeneinander */
    margin-bottom: 0; /* Entfernt den alten vertikalen Abstand */
    font-size: 24px; /* Leicht kompakter für Mobilgeräte */
  }
}
</style>