body {
  font-family: Arial, sans-serif;
  background-color: #000;
  color: #fff;
  text-align: center;
  padding: 20px;
}

.carousel-container {
  perspective: 1200px;
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 50px auto;
  width: 100%;
  height: 60vh; /* take 60% of viewport height */
  max-height: 500px; /* optional, avoid being too tall on huge screens */
}


.carousel {
  width: 80%;       /* takes most of the container width */
  height: 100%;     /* fills container height */
  position: relative;
  transform-style: preserve-3d;
  transition: transform 1s;
}


.card {
  position: absolute;
  width: 40%;      /* 40% of carousel width */
  height: 50%;     /* 50% of carousel height */
  max-width: 300px;
  max-height: 180px;
  left: 50%;
  top: 50%;
  transform-style: preserve-3d;
  transform-origin: center center;
  border-radius: 10px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
  background: #fff;
  transition: transform 1s;
}


.card img {
  width: 100%;
  height: 100%;
  border-radius: 10px;
}

.card-info {
  margin-top: 30px;
  text-align: center;
  font-size: 1.2rem;
  width: 90%;
  max-width: 1000px; /* bigger on desktops */
  margin-left: auto;
  margin-right: auto;
}

.info-content {
  display: none;
  opacity: 0;
  transition: opacity 0.5s;
}

.info-content.active {
  display: block;
  opacity: 1;
}

.carousel-controls {
  margin-top: 30px;
}

.carousel-controls button {
  margin: 0 10px;
  padding: 10px 30px;
  font-size: 1rem;
  background-color: #fff;
  color: #000;
  border: none;
  border-radius: 20px;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.carousel-controls button:hover {
  background-color: #ddd;
}

@media (max-width: 768px) {
  .carousel-container { height: 50vh; }
  .card { width: 60%; height: 50%; }
  .card-info { font-size: 1rem; }
}

@media (max-width: 480px) {
  .carousel-container { height: 40vh; }
  .card { width: 70%; height: 50%; }
  .card-info { font-size: 0.9rem; }
}
