body {
  font-family: 'Arial', sans-serif;
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  background-color: #f5f5f5;
}

.container {
  width: 100%;
  max-width: 600px;
  padding: 20px;
  background-color: #fff;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  border-radius: 10px;
}

h1 {
  text-align: center;
  margin-bottom: 20px;
}

input[type="text"] {
  width: 100%;
  padding: 10px;
  margin-bottom: 10px;
  border: 1px solid #ddd;
  border-radius: 5px;
}

button {
  width: 100%;
  padding: 10px;
  background-color: #007bff;
  color: #fff;
  border: none;
  border-radius: 5px;
  cursor: pointer;
}

button:hover {
  background-color: #0056b3;
}

.response-message {
  margin: 20px 0;
  font-weight: bold;
}

.product-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 15px;
}

.product-card img {
  width: 100%;
  height: 150px;
  object-fit: cover;
  border-radius: 5px;
}


.product-card img {
  width: 100%;
  height: auto;
  border-radius: 5px;
}

.product-card h3 {
  margin: 10px 0 5px;
  font-size: 16px;
}


/* Flip card container */
.flip-card {
  width: 200px;
  height: 250px;
  perspective: 1000px; /* Creates the 3D effect */
  margin: 10px;
  display: inline-block;
}

/* Inner container for front and back */
.flip-card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  text-align: center;
  transition: transform 0.6s;
  transform-style: preserve-3d;
}

/* Flip on hover */
.flip-card:hover .flip-card-inner {
  transform: rotateY(180deg);
}

/* Front and back sides */
.flip-card-front,
.flip-card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  backface-visibility: hidden; /* Hides the back side when not flipped */
  border-radius: 5px;
  overflow: hidden;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

/* Front side style */
.flip-card-front {
  background: #f9f9f9;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.flip-card-front img {
  width: 100%;
  height: 150px;
  object-fit: cover;
  border-radius: 5px 5px 0 0;
}

.flip-card-front h3 {
  margin: 10px 0 0;
  font-size: 1rem;
}

/* Back side style with scrolling and top alignment */
.flip-card-back {
  background: #fff;
  color: #333;
  transform: rotateY(180deg);
  display: flex;
  flex-direction: column; /* Stack content vertically */
  align-items: flex-start; /* Align content to the top */
  justify-content: flex-start; /* Ensure content starts at the top */
  padding: 10px;
  font-size: 0.9rem;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);

  overflow-y: auto; /* Enable vertical scrolling */
  word-wrap: break-word; /* Break long words */
  height: 100%;
}
