.carousel {
  position: relative;
  display: contents;
  overflow: hidden;
}

.carousel-cards-container {
  position: absolute;
  bottom: 0;
  z-index: 2;
  width: 100%;
  padding: 1.5rem 0;
  overflow: hidden;
  -webkit-overflow-scrolling: touch;
  touch-action: pan-x;
}

.carousel-cards {
  display: flex;
  padding: 0;
  transform: translate3d(0, 0, 0);
  transition: transform 0.3s cubic-bezier(0.1, 0, 0.3, 1);
  will-change: transform;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  perspective: 1000;
  -webkit-perspective: 1000;
}

.carousel-nav-btn {
  position: absolute;
  top: 50%;
  z-index: 10;
  padding: 10px;
  border: none;
  border-radius: 50%;
  background-color: rgb(0 0 0 / 50%);
  color: white;
  transform: translateY(-50%);
  transition: background-color 0.3s ease, transform 0.3s ease;
  cursor: pointer;
  will-change: background-color, transform;
}

.carousel-nav-btn {
  padding: 10px;
  border: none;
  border-radius: 5px;
  background-color: var(--primary-color);
  color: white;
  font-size: 18px;
  cursor: pointer;
}

.carousel-nav-btn:hover {
  background-color: rgb(0 0 0 / 70%);
  transform: translateY(-50%) scale(1.1);
}

.carousel-nav-btn:active {
  transform: translateY(-50%) scale(0.95);
}

.carousel-nav-btn:disabled {
  background-color: #aaa;
  cursor: not-allowed;
}

.carousel-cards-container {
  width: 100%;
  margin: 0 auto;
  overflow: hidden;
}

.location-card {
  flex: 0 0 auto;
  width: 220px !important;
  height: 300px;
  margin-right: 16px;
  border-radius: 16px;
  background-color: var(--secondary-color);
  color: var(--background-color);
  transform: translateZ(0);
  -webkit-transform: translateZ(0);
  overflow: hidden;
  will-change: transform;
  backface-visibility: hidden;
  cursor: pointer;
  perspective: 1000px;
  -webkit-perspective: 1000px;
  transition: transform 0.1s ease;
  touch-action: pan-y pinch-zoom;
}

.location-card:hover {
  box-shadow: 5px 5px 10px rgb(0 0 0 / 70%);
}

.location-card img {
  width: 100%;
  height: 50% !important;
  border: none !important;
  transition: transform 0.3s ease;
  object-fit: cover;
}

.location-card-content {
  position: absolute;
  bottom: 0;
  display: flex !important;
  flex-direction: column !important;
  justify-content: space-around !important;
  height: 45%;
  transition: transform 0.3s ease;
}

.distance {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.location-card-content h3 {
  margin: 0 !important;
  font-size: 20px !important;
}

.location-card-content p {
  margin: 0;
  text-decoration: none;
  padding-top: 24px;
}

.location-card:hover .location-card-content {
  transform: translateY(0);
}

.location-card h3 {
  margin-bottom: 0.5rem;
  font-size: 1.2rem;
}

.location-card p {
  font-size: 14px;
  line-height: 1.2;
  font-weight: 400 !important;
}

.location-distance {
  margin-top: 0.5rem;
  font-weight: 700;
  text-decoration: underline !important;
}

#prev-card {
  left: 10px;
}

#next-card {
  right: 10px;
}

.location-card-content h3 {
  text-shadow: 1px 1px 2px rgb(0 0 0 / 80%);
  padding-top: 12px;
  font-weight: 600 !important;
}

.location-card-content p {
  width: 100%;
  color: #f0f0f0;
}

.location-card.highlighted {
  transform: scale(1.1) translateZ(0);
  transition: transform 0.3s ease;
  box-shadow: 0 4px 8px rgb(0 0 0 / 30%);
}

.location-card.disabled {
  opacity: 0.8;
  cursor: not-allowed;
}

.location-card.visited {
  border-color: var(--secondary-color);
}

.location-card img {
  width: 100%;
  object-fit: cover;
  border-bottom: 1px solid #ccc;
  border-top-left-radius: 5px;
  border-top-right-radius: 5px;
}

.location-card-content {
  /* padding: 10px; */
}

#prev-card {
  display: none;
}

#next-card {
  display: none;
}

.location-card-content {
  position: relative;
  padding-right: 36px;
  padding-left: 12px;
}

.card-text-content {
  display: flex;
  flex-direction: column;
  height: 100%;
  /* justify-content: space-around; */
}

.card-action-button {
  position: absolute;
  bottom: 0px;
  right: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background-color: white;
  border-radius: 50%;
  border: none;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  transition: all 0.3s ease;
  z-index: 10;
  cursor: pointer;
}

.card-action-button:hover {
  transform: scale(1.1);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.card-action-button:active {
  transform: scale(0.95);
}

.card-status-icon {
  width: 32px;
  height: 32px;
  fill: none;
}

.card-status-icon.arrow {
  stroke: #0044cc;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.card-status-icon.completed circle {
  fill: #4caf50;
  stroke: none;
}

.card-status-icon.completed path {
  stroke: white;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}

/* Füge diese Styles an das Ende deiner carousel.css hinzu */

/* Visited Card Styling - für abgeschlossene Stories */
.location-card.visited .card-action-button {
  background-color: #4caf50 !important; /* Grüner Hintergrund für abgeschlossene Cards */
  box-shadow: 0 2px 8px rgba(76, 175, 80, 0.3);
}

.location-card.visited .card-action-button:hover {
  transform: scale(1.05); /* Weniger Hover-Effekt bei abgeschlossenen Cards */
  box-shadow: 0 4px 12px rgba(76, 175, 80, 0.4);
  background-color: #4caf50 !important; /* Grün bleibt beim Hover */
}

/* Optional: Leichte Anpassung der Card selbst bei completed Status */
.location-card.visited {
  border: 2px solid #4caf50; /* Grüner Rand für completed Cards */
}

/* Stelle sicher, dass der weiße Haken gut sichtbar ist */
.location-card.visited .card-status-icon.completed circle {
  fill: #4caf50;
}

.location-card.visited .card-status-icon.completed path {
  stroke: white;
  stroke-width: 2.5; /* Etwas dicker für bessere Sichtbarkeit */
}

/* Completion Card Styles */
.completion-card {
  flex: 0 0 auto;
  width: 220px !important;
  height: 300px;
  margin-right: 16px;
  border-radius: 16px;
  background-color: var(--secondary-color);
  color: var(--background-color);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 1rem;
  box-sizing: border-box;
  cursor: pointer;
  transform: translateZ(0);
  -webkit-transform: translateZ(0);
  will-change: transform;
  backface-visibility: hidden;
  perspective: 1000px;
  -webkit-perspective: 1000px;
  transition: transform 0.1s ease;
  touch-action: pan-y pinch-zoom;
}

.completion-card h3 {
  margin: 0 0 0.25rem 0;
  font-size: 16px !important;
  font-weight: 600 !important;
  text-align: left;
  line-height: 1.2;
}

.completion-card p {
  margin: 0;
  font-size: 14px;
  line-height: 1.4;
  text-align: left;
  color: #f0f0f0;
  font-weight: 400;
}

/* Completion button margins for inline layout */
.completion-card .completion-button {
  margin: 0.5rem 0;
  width: 100%;
  box-sizing: border-box;
}

.completion-button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.25rem;
  border-radius: 8px;
  border: 2px solid #cecccd;
  background: transparent;
  color: white;
  text-decoration: none;
  font-size: 12px;
  font-weight: 500;
  transition: all 0.3s ease;
  cursor: pointer;
  min-height: 40px;
}

.completion-button:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.5);
  transform: translateY(-1px);
}

.completion-button:active {
  transform: translateY(0);
}

.completion-button svg {
  width: 16px;
  height: 16px;
  height: 16px;
  fill: currentColor;
}

.completion-card:hover {
  box-shadow: 5px 5px 10px rgb(0 0 0 / 70%);
}

.completion-card.highlighted {
  transform: scale(1.1) translateZ(0);
  transition: transform 0.3s ease;
  box-shadow: 0 4px 8px rgb(0 0 0 / 30%);
}

