/* Reset and base styles */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: Arial, sans-serif;
}

body {
  background-color: #f5f5f5;
  color: #333;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
}

header {
  background-color: #ff5722;
  color: white;
  padding: 10px 0;
}

.header-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-size: 1.8rem;
  font-weight: bold;
}

nav a {
  color: white;
  text-decoration: none;
  margin-left: 20px;
  font-weight: bold;
}

nav a:hover {
  text-decoration: underline;
}

.search-container {
  margin-top: 10px;
  text-align: center;
}

#search-input {
  width: 100%;
  max-width: 400px;
  padding: 8px 12px;
  border-radius: 20px;
  border: none;
  font-size: 1rem;
}

main {
  flex-grow: 1;
  padding: 20px 0;
}

h2 {
  margin-bottom: 20px;
  color: #ff5722;
}

.product-list {
  display: grid;
  grid-template-columns: repeat(auto-fill,minmax(220px,1fr));
  gap: 20px;
}

.product-card {
  background-color: white;
  border-radius: 8px;
  box-shadow: 0 2px 6px rgb(0 0 0 / 0.1);
  padding: 15px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: box-shadow 0.3s ease;
}

.product-card:hover {
  box-shadow: 0 4px 12px rgb(0 0 0 / 0.2);
}

.product-image {
  width: 100%;
  height: 180px;
  object-fit: contain;
  margin-bottom: 10px;
}

.product-title {
  font-weight: bold;
  font-size: 1.1rem;
  margin-bottom: 8px;
  color: #333;
  flex-grow: 1;
}

.product-price {
  color: #ff5722;
  font-weight: bold;
  margin-bottom: 10px;
}

.product-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

button {
  background-color: #ff5722;
  border: none;
  color: white;
  padding: 8px 12px;
  border-radius: 4px;
  cursor: pointer;
  font-weight: bold;
  transition: background-color 0.3s ease;
}

button:hover {
  background-color: #e64a19;
}

footer {
  background-color: #333;
  color: white;
  padding: 15px 0;
  text-align: center;
  font-size: 0.9rem;
  margin-top: auto;
}

/* Responsive */
@media (max-width: 600px) {
  .header-container {
    flex-direction: column;
    align-items: flex-start;
  }

  nav {
    margin-top: 10px;
  }

  nav a {
    margin-left: 0;
    margin-right: 15px;
  }

  .product-list {
    grid-template-columns: repeat(auto-fill,minmax(150px,1fr));
  }
}