.carousel-container {
  position: relative;
  display: flex;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px 40px;
  background-color: #f2f5f8;
  font-family: Arial, sans-serif;
  box-sizing: border-box;
}

.carousel-track-container {
  width: 100%;
  overflow-x: auto;
  scroll-behavior: smooth;
  scrollbar-width: none;
  scroll-snap-type: x mandatory;
}

.carousel-track-container::-webkit-scrollbar {
  display: none;
}

.carousel-track {
  display: flex;
  gap: 20px;
}

/* Die gesamte Karte ist jetzt ein Klickbereich */
.carousel-card {
  flex: 0 0 calc((100% - 40px) / 3);
  min-width: calc((100% - 40px) / 3);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  box-sizing: border-box;
  padding: 15px;
  border-radius: 8px;
  scroll-snap-align: start;
  font-family: 'Noto Sans', sans-serif;
  text-decoration: none !important; /* Entfernt Unterstreichung bei <a> */
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

/* Hover-Effekt für die gesamte Karte */
.carousel-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* Logo ganz oben */
.card-logo {
  height: 90px;
  width: 100%;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  margin-bottom: 15px;
}

.card-logo img {
  max-height: 90px;
  max-width: 100%;
  object-fit: contain;
}

.card-title {
  font-family: 'Noto Sans', sans-serif;
  font-size: 20px;
  font-weight: bold;
  color: #1f323d !important;
  margin: 0 0 10px 0;
  white-space: normal;
  hyphens: auto;
  hyphenate-limit-chars: 12 4 4;
}

.card-text {
  font-family: 'Noto Sans', sans-serif;
  font-size: 16px;
  line-height: 1.4;
  color: #1f323d !important;
  padding-top: 0px !important;
  padding-bottom: 0px !important;
  margin: 0;
}

/* Pfeile */
.carousel-btn {
  background-color: #ff8e00;
  color: #ffffff;
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  font-weight: bold;
  flex-shrink: 0;
  z-index: 2;
  padding: 0;
  line-height: 1;
}

.prev-btn { margin-right: 15px; }
.next-btn { margin-left: 15px; }

/* Editor Anpassungen */
.carousel-track > .block-editor-inner-blocks,
.carousel-track > .block-editor-inner-blocks > .block-editor-block-list__layout,
.carousel-track-container .wp-block-mls-slider-container {
  display: flex !important;
  gap: 20px !important;
  width: 100%;
}

.wp-block-mls-slider-card,
.carousel-card-editor {
  flex: 0 0 calc((100% - 40px) / 3) !important;
  box-sizing: border-box;
}

/* Media Queries */
@media (max-width: 1220px) {
  .carousel-container {
    max-width: 95%;
    padding: 20px 30px;
  }

  .carousel-card,
  .wp-block-mls-slider-card {
    flex: 0 0 calc((100% - 20px) / 2) !important;
    min-width: calc((100% - 20px) / 2);
  }
}

@media (max-width: 600px) {
  .carousel-container {
    max-width: 95%;
    padding: 20px 15px;
  }

  .carousel-card,
  .wp-block-mls-slider-card {
    flex: 0 0 100% !important;
    min-width: 100%;
  }
}