/* Reset some basic styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* Navbar styling */
header {
  background-color: #2c3e50;
  padding: 1rem 2rem;
  color: white;
}

.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.navbar h1 {
  font-size: 1.8rem;
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 1.5rem;
}

.nav-links a {
  color: white;
  text-decoration: none;
  font-weight: bold;
}

.nav-links a:hover {
  color: #1abc9c;
}

/* Main container */
.market-container {
  padding: 2rem 1rem;
  max-width: 1200px;
  margin: auto;
}

/* Category filter section */
.filter-bar {
  text-align: center;
  margin-bottom: 2rem;
}

.filter-bar h2 {
  font-size: 1.5rem;
  margin-bottom: 0.8rem;
}

.categories {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
}

.category-btn {
  background-color: #2980b9;
  color: white;
  border: none;
  padding: 0.6rem 1.2rem;
  border-radius: 5px;
  cursor: pointer;
  font-weight: 500;
  transition: background-color 0.3s ease;
}

.category-btn:hover {
  background-color: #1abc9c;
}
.category-btn.active {
  background-color: #1abc9c;
  color: white;
}


/* Items grid */
.items-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
}

/* Each item */
.item-card {
  background-color: #fff;
  padding: 1rem;
  border-radius: 10px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
  text-align: center;
  transition: transform 0.2s ease;
}

.item-card:hover {
  transform: translateY(-4px);
}

.item-card img {
  width: 100%;
  max-height: 150px;
  object-fit: cover;
  border-radius: 6px;
}

.item-card h3 {
  margin: 0.7rem 0 0.4rem;
  font-size: 1.1rem;
}

.item-card p {
  color: #27ae60;
  font-weight: bold;
  margin-bottom: 0.6rem;
}

.item-card a {
  display: inline-block;
  text-decoration: none;
  background-color: #27ae60;
  color: white;
  padding: 0.4rem 1rem;
  border-radius: 5px;
  transition: background-color 0.3s ease;
}

.item-card a:hover {
  background-color: #219150;
}

/* Footer */
footer {
  background-color: #ecf0f1;
  text-align: center;
  padding: 1rem;
  margin-top: 2rem;
  font-size: 0.9rem;
  color: #555;
}
