body {
  font-family: Arial, sans-serif;
  margin: 0;
  padding: 0;
  background: #f8f8f8;
  color: #333;
}

header, footer {
  text-align: center;
  padding: 1rem;
  background: #4CAF50;
  color: white;
}

.store-search, .product-search {
  text-align: center;
  padding: 1rem;
}

input[type="text"] {
  padding: 0.5rem;
  width: 250px;
  margin-right: 0.5rem;
}

button {
  padding: 0.5rem 1rem;
  cursor: pointer;
}

#stores, #results {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  padding: 1rem;
  gap: 1rem;
}

.item {
  background: white;
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.15);
  width: 200px;
  padding: 0.5rem;
  text-align: center;
  transition: transform 0.2s;
}

.item:hover {
  transform: scale(1.03);
}

.item img {
  max-width: 100%;
  border-radius: 4px;
}

.item-info {
  padding: 0.5rem 0;
}

.loading {
  font-style: italic;
}

/* Fade-in animation */
.fade-in {
  animation: fadeIn 0.5s ease forwards;
  opacity: 0;
}

@keyframes fadeIn {
  to { opacity: 1; }
}

/* Modal styling */
.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  padding-top: 50px;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0,0,0,0.5);
}

.modal-content {
  background-color: #fff;
  margin: auto;
  padding: 20px;
  border-radius: 8px;
  width: 90%;
  max-width: 500px;
  position: relative;
}

.close-btn {
  color: #aaa;
  float: right;
  font-size: 28px;
  font-weight: bold;
  cursor: pointer;
}

.close-btn:hover {
  color: black;
}