:root {
  --primary-green: #2ecc71;
  --dark-green: #27ae60;
  --light-green: #3498db;
  --background-gray: #f4f4f4;
  --text-dark: #333;
  --primary-green-dark: #27ae60;
  --primary-green-light: #34c759;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Roboto', 'Arial', sans-serif;
  background-color: var(--background-gray);
  color: var(--text-dark);
  line-height: 1.6;
}

.navbar {
  background-color: var(--primary-green);
  color: white;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 20px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.navbar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
}

.navbar-brand {
  display: flex;
  align-items: center;
  color: white;
  text-decoration: none;
  font-weight: bold;
}

.navbar-brand img {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  margin-right: 10px;
  object-fit: cover;
}

.navbar-menu {
  display: flex;
  align-items: center;
}

.nav-link {
  color: white;
  text-decoration: none;
  margin-left: 15px;
  display: flex;
  align-items: center;
}

.nav-link i {
  margin-right: 5px;
}

.search-results-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
  background-color: white;
}

.search-results-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  border-bottom: 2px solid var(--primary-green);
  padding-bottom: 10px;
}

.search-form {
  display: flex;
}

.search-form input {
  padding: 8px;
  border: 1px solid #ddd;
  border-right: none;
  flex-grow: 1;
}

.search-form button {
  padding: 8px 12px;
  background-color: var(--primary-green);
  color: white;
  border: 1px solid var(--primary-green);
  cursor: pointer;
}

.giveaway-badge {
    background-color: #eafaf1;
    color: #15896d;
    border: 1px solid #b5e7cd;
    padding: 6px 10px;
    border-radius: 10px;
    display: inline-block;
    margin-bottom: 8px;
    font-size: 0.95em;
    font-weight: 500;
}

.listings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 15px;
}

.listing-card {
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: box-shadow 0.3s ease;
}

.listing-thumbnail {
  width: 100%;
  height: 250px;
  object-fit: cover;
}

.listing-details {
  padding: 15px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.listing-details h2 {
  font-size: 1.1rem;
  margin-bottom: 10px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.description {
  font-size: 0.9rem;
  color: #666;
  margin-bottom: 10px;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.listing-meta {
  display: flex;
  justify-content: space-between;
  margin-top: auto;
  padding-top: 10px;
}

.price {
  color: var(--primary-green);
  font-weight: bold;
}

.location {
  color: #888;
  font-size: 0.9rem;
}

.view-details-btn {
  display: block;
  width: 100%;
  text-align: center;
  background-color: var(--primary-green);
  color: white;
  padding: 10px;
  text-decoration: none;
  margin-top: 10px;
}

.pagination {
  display: flex;
  justify-content: center;
  margin-top: 20px;
}

.pagination a {
  margin: 0 5px;
  padding: 8px 12px;
  background-color: var(--primary-green);
  color: white;
  text-decoration: none;
  border-radius: 4px;
}

.no-results {
  text-align: center;
  padding: 30px;
  background-color: #f9f9f9;
}

.burger-menu {
  display: none;
}

@media (max-width: 768px) {
  .navbar {
    position: relative;
    display: flex;
    justify-content: space-between;
    align-items: center;
  }

  .burger-menu {
    display: block !important;
    cursor: pointer;
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 1002;
  }

  .burger-icon {
    display: block !important;
    font-size: 24px;
    color: white;
    line-height: 1;
  }

  .navbar-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background-color: var(--primary-green);
    flex-direction: column;
    align-items: stretch;
    z-index: 1000;
  }

  .navbar-menu.is-active {
    display: flex;
  }

  .nav-link {
    padding: 15px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    text-align: center;
  }

  .navbar-brand {
    z-index: 1001;
    display: flex;
    align-items: center;
  }

  .listings-grid {
    grid-template-columns: 1fr;
  }

  .navbar {
    flex-direction: column;
  }

  .navbar-menu {
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 10px;
  }

  .nav-link {
    margin: 0 10px 10px;
  }

  .search-results-header {
    flex-direction: column;
    align-items: stretch;
  }

  .search-form {
    margin-top: 10px;
  }
}
