.hero-tagcloud,
.hero-tagcloud * {
  box-sizing: border-box !important;
}

/* Desktop: Hero-Tagcloud rechts als 50%-Spalte */
section.hero-tagcloud {
  width: 50% !important;
  max-width: 50% !important;
  margin-left: 50% !important;
  z-index: 5;
}

/* Tag-Basis */
.hero-tagcloud .hero-tagcloud__tag {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 0.45em !important;

  width: max-content !important;
  max-width: min(42%, 320px) !important;

  margin: 0 !important;
  padding: 0.56em 0.84em !important;

  border: 2px solid #228ff2 !important;
  border-radius: 0.58em !important;

  background: rgba(255, 255, 255, 0.94) !important;
  box-shadow:
    0 0 0 0.22em rgba(34, 143, 242, 0.12),
    0 0.8em 1.8em rgba(14, 80, 150, 0.18) !important;

  color: #151515 !important;

  font-family: "Montserrat", sans-serif !important;
  font-size: clamp(10px, 1.55vw, 15px) !important;
  font-weight: 600 !important;
  line-height: 1.18 !important;
  letter-spacing: 0.01em !important;

  text-align: center !important;
  text-decoration: none !important;
  white-space: nowrap !important;

  cursor: pointer !important;
  overflow: hidden !important;
}

.hero-tagcloud .hero-tagcloud__tag:hover,
.hero-tagcloud .hero-tagcloud__tag:focus-visible {
  border-color: #0877d8 !important;
  box-shadow:
    0 0 0 0.3em rgba(34, 143, 242, 0.18),
    0 1em 2em rgba(14, 80, 150, 0.24) !important;
  outline: none !important;
}

.hero-tagcloud .tag__check {
  color: #00a51f !important;
  font-size: 1.42em !important;
  font-weight: 800 !important;
  line-height: 1 !important;
}

.hero-tagcloud .tag__spark,
.hero-tagcloud .tag__ok {
  font-size: 0.95em !important;
  line-height: 1 !important;
}

@media (max-width: 1112px) {
  .hero-tagcloud .hero-tagcloud__tag {
    white-space: normal !important;
  }
}

/* Floating */
@keyframes tagcloud-float {
  0%,
  100% {
    margin-top: 0;
    rotate: -0.25deg;
  }

  50% {
    margin-top: -0.55em;
    rotate: 0.25deg;
  }
}

/* Zwischenbereich: kurz vor Mobile */
@media (min-width: 701px) and (max-width: 1000px) {
  .hero-tagcloud {
    aspect-ratio: 1.05 / 1 !important;
  }

  .hero-tagcloud__image {
    width: 88% !important;
  }

  .hero-tagcloud .hero-tagcloud__tag {
    max-width: 52% !important;
    font-size: clamp(11px, 1.8vw, 14px) !important;
    white-space: nowrap !important;
    padding: 0.5em 0.7em !important;
  }

  section.hero-tagcloud {
    width: 100% !important;
    max-width: 100% !important;
    margin-left: 0 !important;
  }
}

/* Mobile */
@media (max-width: 700px) {
  section.hero-tagcloud {
    width: 100% !important;
    max-width: 100% !important;
    margin-left: 0 !important;
  }

  .hero-tagcloud {
    aspect-ratio: 0.88 / 1 !important;
  }

  .hero-tagcloud__image {
    width: 96% !important;
  }

  .hero-tagcloud .hero-tagcloud__tag {
    max-width: 46% !important;
    font-size: clamp(11px, 3.4vw, 15px) !important;
    white-space: normal !important;
    padding: 0.48em 0.62em !important;
    line-height: 1.12 !important;
  }

  .hero-tagcloud .tag__spark,
  .hero-tagcloud .tag__ok {
    display: none !important;
  }
}

/* Optional: sehr kleine Geräte */
@media (max-width: 380px) {
  .hero-tagcloud .hero-tagcloud__tag {
    max-width: 44% !important;
    font-size: clamp(10px, 3.45vw, 13px) !important;
    padding: 0.44em 0.56em !important;
  }
  .hero-tagcloud .tag__check,
  .hero-tagcloud .tag__spark,
  .hero-tagcloud .tag__ok {
    display: none;
  }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  .hero-tagcloud__tag {
    animation: none !important;
  }
}
